code: public static TernaryValue isStrWhiteSpaceChar(int c) {
      switch (c) {
        case '\u000B': // <VT>
          return TernaryValue.UNKNOWN;  // IE says "no", ECMAScript says "yes"
        case ' ': // <SP>
        case '\n': // <LF>
        case '\r': // <CR>
        case '\t': // <TAB>
        case '\u00A0': // <NBSP>
        case '\u000C': // <FF>
        case '\u2028': // <LS>
        case '\u2029': // <PS>
        case '\uFEFF': // <BOM>
          return TernaryValue.TRUE;
        default:
          return (Character.getType(c) == Character.SPACE_SEPARATOR)
              ? TernaryValue.TRUE : TernaryValue.FALSE;
      }
    }
docs: Copied from Rhino's ScriptRuntime