This class provides an immutable
object wrapper around the primitive
charValue( ) returns the
char value of a
Comparable interface so that
Character objects can be ordered and sorted. The
static methods are the most interesting thing about this class,
however: they categorize
char values based on the
categories defined by the
Unicode standard. (Some
of the methods are only useful if you have a detailed understanding
of that standard.) Static methods beginning with
a character is in a
isLowerCase( ) are some of the most useful.
Note that these methods work for any Unicode character, not just with
the familiar Latin letters and Arabic numbers of the ASCII character
a constant that identifies the category of a character.
returns a separate
DIRECTIONALITY_ constant that specifies the
“directionality category” of a
In addition to testing the category of a character, this class also
defines static methods for converting characters.
returns the uppercase equivalent of the
specified character (or returns the character itself if the character
is uppercase or has no uppercase equivalent).
) converts instead to lowercase.
digit( ) returns the integer equivalent of a given character in a given radix (or base; ...