public class Chars extends Object
| 构造器和说明 |
|---|
Chars() |
| 限定符和类型 | 方法和说明 |
|---|---|
static char |
b2c(byte b) |
static byte |
c2b(char c) |
static int |
compare(char x,
char y)
Compares two
char values numerically. |
static boolean |
isAlphabetic(int codePoint)
Determines if the specified character (Unicode code point) is an alphabet.
|
static boolean |
isAscii(char ch) |
static boolean |
isAsciiPrintable(char ch) |
static boolean |
isLowerCase(byte value) |
static boolean |
isLowerCase(char value) |
static boolean |
isLowOrUpperCase(byte value) |
static boolean |
isLowOrUpperCase(char value) |
static boolean |
isNumber(char c) |
static boolean |
isUpperCase(byte value) |
static boolean |
isUpperCase(char value) |
static int |
toInt(char c) |
static byte |
toLowerCase(byte c) |
static char |
toLowerCase(char c) |
static byte |
toUpperCase(byte b) |
static char |
toUpperCase(char b) |
public static boolean isAlphabetic(int codePoint)
A character is considered to be alphabetic if its general category type,
provided by getType(codePoint), is any of
the following:
UPPERCASE_LETTER
LOWERCASE_LETTER
TITLECASE_LETTER
MODIFIER_LETTER
OTHER_LETTER
LETTER_NUMBER
codePoint - the character (Unicode code point) to be tested.true if the character is a Unicode alphabet
character, false otherwise.
copy from java 1.7 Character.isAlphabetic
public static boolean isAscii(char ch)
public static boolean isAsciiPrintable(char ch)
public static boolean isNumber(char c)
public static int toInt(char c)
public static char toLowerCase(char c)
public static byte toLowerCase(byte c)
public static byte toUpperCase(byte b)
public static char toUpperCase(char b)
public static boolean isLowerCase(byte value)
public static boolean isLowerCase(char value)
public static boolean isUpperCase(byte value)
public static boolean isUpperCase(char value)
public static boolean isLowOrUpperCase(char value)
public static boolean isLowOrUpperCase(byte value)
public static byte c2b(char c)
public static char b2c(byte b)
public static int compare(char x,
char y)
Compares two char values numerically. This is the same functionality as provided in Java 7.
x - the first char to comparey - the second char to compare0 if x == y;
a value less than 0 if x < y; and
a value greater than 0 if x > yCopyright © 2020. All rights reserved.