|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.foray.common.XMLCharacter
public final class XMLCharacter
This class provides assistance in handling certain XML-specific tasks. Appendix B of the XML 1.0 Standard defines several character classes. The methods in this class are used to map a given character to these classes.
Method Summary | |
---|---|
static String |
expandEntityReference(char c)
Takes an entity reference character and converts it to its expanded value. |
static CharSequence |
expandEntityReferences(CharSequence rawText)
For a sequence of raw text characters, expands entity references. |
static boolean |
isBaseChar(char c)
Indicates whether a given char is a "base" character as defined in the XML specification. |
static boolean |
isCombiningChar(char c)
Indicates whether a given char is a "combining" character as defined in the XML specification. |
static boolean |
isDigit(char c)
Indicates whether a given char is a "digit" character as defined in the XML specification. |
static boolean |
isEntityReference(char c)
Indicates whether the input is one of the five predefined XML entity references. |
static boolean |
isExtender(char c)
Indicates whether a given char is an "extender" character as defined in the XML specification. |
static boolean |
isIdeographic(char c)
Indicates whether a given char is an "ideographic" character as defined in the XML specification. |
static boolean |
isLetter(char c)
Indicates whether a given char is a "letter" character as defined in the XML specification. |
static boolean |
isNCName(String input)
Indicates whether the argument is a valid NAME as defined by XML. |
static boolean |
isXMLWhitespace(char c)
Tests a character for inclusion in XML whitespace. |
static boolean |
isXMLWhitespace(char[] chars)
Tests whether a given sequence of chars is all XML whitespace. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static boolean isBaseChar(char c)
c
- The char to be tested.
c
is a "base" character.public static boolean isIdeographic(char c)
c
- The char to be tested.
c
is an "ideographic" character.public static boolean isCombiningChar(char c)
c
- The char to be tested.
c
is a "combining" character.public static boolean isDigit(char c)
c
- The char to be tested.
c
is a "digit" character.public static boolean isExtender(char c)
c
- The char to be tested.
c
is an "extender" character.public static boolean isLetter(char c)
c
- The char to be tested.
c
is a "letter" character.public static boolean isXMLWhitespace(char c)
c
- The character to be tested.
public static boolean isXMLWhitespace(char[] chars)
chars
- The sequence of character to be tested.
chars
is XML whitespace.public static boolean isNCName(String input)
input
- The String to check.
input
is a valid XML NAME.public static boolean isEntityReference(char c)
c
- The char to be tested.
c
is a predefined XML entity reference.public static String expandEntityReference(char c)
c
- The char which should be converted to a predefined XML entity
reference.
c
.public static CharSequence expandEntityReferences(CharSequence rawText)
rawText
- The raw text which should be expanded.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |