|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.tomshut.util.text.CharSequenceUtil
public class CharSequenceUtil
Field Summary | |
---|---|
static char[] |
PSEUDO_BETA_CODE
|
Method Summary | |
---|---|
static java.lang.CharSequence |
duration(long millis,
boolean writeMillis)
|
static boolean |
isBasicLatinUppercase(java.lang.CharSequence seq)
Checks if a char sequence contains only characters between 0x0020 (space) and 0x007E (~) |
static boolean |
isDigits(java.lang.CharSequence str)
Checks if all characters in the string are digits |
static boolean |
isHex(java.lang.CharSequence str)
Checks if all characters in the string may represent a hexadecimal literal |
static boolean |
isLatin(java.lang.CharSequence seq)
Checks if a char sequence contains only characters between 0x0020 (space) and 0x007E (~) as well as characters between 0x00A0 and 0x00FF |
static boolean |
isLetters(java.lang.CharSequence str)
Checks if all characters in the string are letters |
static boolean |
isLettersOrDigits(java.lang.CharSequence str)
Checks if all characters in the string are letters or digits |
static java.lang.CharSequence |
makeLatin(java.lang.CharSequence seq)
This method maps all characters which are not between 0x0020 (space) and 0x007E or between 0x00A0 and 0x00FF to values between 0x0020 and 0x007E by crude and/or bit operations. |
static java.lang.CharSequence |
replaceJavaEscapeChars(java.lang.CharSequence str)
Replaces java style escape characters in the string |
static java.lang.CharSequence |
toBasicLatinUpperCase(java.lang.CharSequence seq)
This method converts the given CharSequence to upper case and replaces supplement characters by their corresponding base characters. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final char[] PSEUDO_BETA_CODE
Method Detail |
---|
public static boolean isDigits(java.lang.CharSequence str)
str
- the string to check
CharacterUtil.isDigit(char)
public static boolean isLetters(java.lang.CharSequence str)
str
- the string to check
CharacterUtil.isLetter(char)
public static boolean isLettersOrDigits(java.lang.CharSequence str)
str
- the string to check
CharacterUtil.isLetterOrDigit(char)
public static boolean isLatin(java.lang.CharSequence seq)
seq
- the sequence to check
public static boolean isBasicLatinUppercase(java.lang.CharSequence seq)
seq
- the sequence to check
public static boolean isHex(java.lang.CharSequence str)
str
- the string to check
CharacterUtil.isHexDigit(char)
public static java.lang.CharSequence replaceJavaEscapeChars(java.lang.CharSequence str)
str
- the string which may contain escaped characters
public static java.lang.CharSequence makeLatin(java.lang.CharSequence seq)
Only exceptions are Greek characters, which are converted using something similar to the Beta Code (using upper and lower case characters instead of upper case characters with optional stars and numbers...).
seq
- the character sequence to make latin
public static java.lang.CharSequence toBasicLatinUpperCase(java.lang.CharSequence seq)
The method converts the characters in the given CharSequence by
All characters in the returned CharSequence are in the range 0x0020 to 0x005F.
seq
- the string to be converted. Characters must be from 0x0020 to
0x007E and/or 0x00A0 to 0x00FF
public static java.lang.CharSequence duration(long millis, boolean writeMillis)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |