com.plumtree.openfoundation.util
Class XPCharacterUtility

java.lang.Object
  extended bycom.plumtree.openfoundation.util.XPCharacterUtility

public class XPCharacterUtility
extends java.lang.Object

XPCharacterUtility contains the utility methods that operate on chars.


Constructor Summary
XPCharacterUtility()
           
 
Method Summary
static int GetASCIIDecimalValue(char c)
          Return 0 - 9 for '0' - '9'.
static boolean IsASCIIDecimalDigit(char c)
          True for '0' - '9' (\\u0030 - \\u0039).
static boolean IsLetterOrDigit(char ch)
          From JDK API 1.3.1 Documentation for Character.isLetterOrDigit() Determines if the specified character is a letter or digit.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XPCharacterUtility

public XPCharacterUtility()
Method Detail

IsLetterOrDigit

public static boolean IsLetterOrDigit(char ch)
From JDK API 1.3.1 Documentation for Character.isLetterOrDigit() Determines if the specified character is a letter or digit. For a more complete specification that encompasses all Unicode characters, see Gosling, Joy, and Steele, The Java Language Specification.

A character is considered to be a letter if and only if it is specified to be a letter or a digit by the Unicode 2.0 standard (category "Lu", "Ll", "Lt", "Lm", "Lo", or "Nd" in the Unicode specification data file). In other words, isLetterOrDigit is true of a character if and only if either isLetter is true of the character or isDigit is true of the character.

Parameters:
ch - the character to be tested.
Returns:
true if the character is a letter or digit; false otherwise.

IsASCIIDecimalDigit

public static boolean IsASCIIDecimalDigit(char c)
True for '0' - '9' (\\u0030 - \\u0039).

Parameters:
c - Character to be verified.
Returns:
true for '0' <= c <= '9'.

GetASCIIDecimalValue

public static int GetASCIIDecimalValue(char c)
Return 0 - 9 for '0' - '9'.

Parameters:
c - a candidate digit to take numeric value
Returns:
numeric value of character as ASCII decimal digit, or -1 if no numeric value,


Copyright 2002, 2003, 2004 Plumtree Software Inc. All Rights Reserved.