title: Java regular expression to match _all_ whitespace characters
body: <p>I'm looking for a regular expression in Java which matches all whitespace characters in a String. "\s" matches only some, it does not match <code>&amp;nbsp;</code> and similar non-ascii whitespaces. I'm looking for a regular expression which matches all (common) white-space characters which can occur in a Java String. </p>
  
  <p>[Edit]</p>
  
  <p>To clarify: I do not mean the string sequence "<code>&amp;nbsp;</code>" I mean the sincle unicode character U+00A0 that is often represented by "<code>&amp;nbsp;</code>", e.g. in HTML, and all other unicode characters with a similar white-space meainig, e.g. "NARROW NO-BREAK SPACE" (U+202F), Word joiner encoded in Unicode 3.2 and above as U+2060, "ZERO WIDTH NO-BREAK SPACE" (U+FEFF) and any other character that can be regareded as white-space.</p>
  
  <p>[Answer] </p>
  
  <p>For my pupose, ie catching all whitespace characters, unicode + traditional, the following expression does the job:</p>
  
  <p><code>[\p{Z}\s]</code></p>
  
  <p>The answer is in the comments below but since it is a bit hidden I repeat it here.</p>