{ int type = Character.getType(c); switch (type) { case Character.LOWERCASE_LETTER: case Character.UPPERCASE_LETTER: case Character.DECIMAL_DIGIT_NUMBER: case Character.OTHER_LETTER: case Character.TITLECASE_LETTER: case Character.LETTER_NUMBER: case Character.COMBINING_SPACING_MARK: case Character.ENCLOSING_MARK: case Character.NON_SPACING_MARK: case Character.MODIFIER_LETTER: if ((c > 0xf900 && c < 0xfffe) || (c >= 0x20dd && c <= 0x20e0)) return false; break; default: if (c != '-' && c != '.' && c != ':' && c != '_' && c != 0x0387 && (c < 0x02bb || c > 0x02c1) && c != 0x0559 && c != 0x06e5 && c != 0x06e6 && c != 0x00b7) return false; } } return true;
return (c == 0x2e || c == 0x2d || c == 0x5f || c == 0x3a || isLetter(c) || isDigit(c) || isCombiningChar(c) || isExtender(c));
  private boolean isNameCharacter(char c)  {    if (input.xml11)      {        if ((c < 0x0041 || c > 0x005a) &&            (c < 0x0061 || c > 0x007a) &&            (c < 0x0030 || c > 0x0039) &&            c != ':' && c != '_' && c != '-' && c != '.' &&            (c < 0x00c0 || c > 0x00d6) &&            (c < 0x00d8 || c > 0x00f6) &&            (c < 0x00f8 || c > 0x02ff) &&            (c < 0x0370 || c > 0x037d) &&            (c < 0x037f || c > 0x1fff) &&            (c < 0x200c || c > 0x200d) &&            (c < 0x2070 || c > 0x218f) &&            (c < 0x2c00 || c > 0x2fef) &&            (c < 0x3001 || c > 0xd7ff) &&            (c < 0xf900 || c > 0xfdcf) &&            (c < 0xfdf0 || c > 0xfffd) &&            (c < 0x10000 || c > 0xeffff) &&            c != 0x00b7 &&             (c < 0x0300 || c > 0x036f) &&            (c < 0x203f || c > 0x2040))          return false;      }    else      {        int type = Character.getType(c);        switch (type)          {          case Character.LOWERCASE_LETTER: // Ll          case Character.UPPERCASE_LETTER: // Lu          case Character.DECIMAL_DIGIT_NUMBER: // Nd          case Character.OTHER_LETTER: // Lo          case Character.TITLECASE_LETTER: // Lt          case Character.LETTER_NUMBER: // Nl          case Character.COMBINING_SPACING_MARK: // Mc          case Character.ENCLOSING_MARK: // Me          case Character.NON_SPACING_MARK: // Mn          case Character.MODIFIER_LETTER: // Lm            if ((c > 0xf900 && c < 0xfffe) ||                (c >= 0x20dd && c <= 0x20e0))              return false;            break;          default:            if (c != '-' && c != '.' && c != ':' && c != '_' &&                c != 0x0387 && (c < 0x02bb || c > 0x02c1) &&                 c != 0x0559 && c != 0x06e5 && c != 0x06e6 && c != 0x00b7)              return false;          }      }    return true;  }