Class Character

Summary

Compare two Character objects

You can compare two Character objects for Character implements Comparable interface (by the way, String is comparable, but StringBuffer not)

int compareTo(Character anotherCharacter) 
int compareTo(Object o) //If the Object is a Character, this function behaves like compareTo(Character). Otherwise, it throws a ClassCastException (as Characters are comparable only to other Characters).

Conversion about characters

Convert a char into digital (int)

public static int digit(char ch, int radix) //radix is between 2 to 36

Convert a digital (int) into char

static char forDigit(int digit, int radix) 

Case conversion

static char toTitleCase(char ch) 
static char toUpperCase(char ch) 

Returns the Unicode numeric value of the character

For example: '\u0BF1': return 100; // TAMIL NUMBER ONE HUNDRED

static int getNumericValue(char ch) 

Determination methods of Character class

isDefined - if defined in Unicode (<F900)
isIdentifierIgnorable

isDigit
isLetter
isLetterOrDigit
isISOControl - if its code is in the range \u0000 through \u001F or in the range \u007F through \u009F

isLowerCase, isUpperCase
isSpaceChar, isWhitespace

isJavaIdentifierPart, isJavaIdentifierStart, 

isUnicodeIdentifierPart, isUnicodeIdentifierStart

 

 

Reference

Sun's Hierarchy For Package java.lang - Class Character