|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.saxon.serialize.charcode.UTF16CharacterSet
public class UTF16CharacterSet
A class to hold some static constants and methods associated with processing UTF16 and surrogate pairs
Field Summary | |
---|---|
static int |
NONBMP_MAX
|
static int |
NONBMP_MIN
|
static char |
SURROGATE1_MAX
|
static char |
SURROGATE1_MIN
|
static char |
SURROGATE2_MAX
|
static char |
SURROGATE2_MIN
|
Method Summary | |
---|---|
static int |
combinePair(char high,
char low)
Return the non-BMP character corresponding to a given surrogate pair surrogates. |
static boolean |
containsSurrogates(CharSequence s)
Test whether a CharSequence contains any surrogates (i.e. |
String |
getCanonicalName()
Get the preferred Java name of the character set. |
static UTF16CharacterSet |
getInstance()
Get the singular instance of this class |
static char |
highSurrogate(int ch)
Return the high surrogate of a non-BMP character |
boolean |
inCharset(int c)
Determine if a character is present in the character set |
static boolean |
isHighSurrogate(int ch)
Test whether the given character is a high surrogate |
static boolean |
isLowSurrogate(int ch)
Test whether the given character is a low surrogate |
static boolean |
isSurrogate(int c)
Test whether a given character is a surrogate (high or low) |
static char |
lowSurrogate(int ch)
Return the low surrogate of a non-BMP character |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int NONBMP_MIN
public static final int NONBMP_MAX
public static final char SURROGATE1_MIN
public static final char SURROGATE1_MAX
public static final char SURROGATE2_MIN
public static final char SURROGATE2_MAX
Method Detail |
---|
public static UTF16CharacterSet getInstance()
public boolean inCharset(int c)
CharacterSet
inCharset
in interface CharacterSet
public String getCanonicalName()
CharacterSet
getCanonicalName
in interface CharacterSet
public static int combinePair(char high, char low)
high
- The high surrogate.low
- The low surrogate.
public static char highSurrogate(int ch)
ch
- The Unicode codepoint of the non-BMP character to be divided.
public static char lowSurrogate(int ch)
ch
- The Unicode codepoint of the non-BMP character to be divided.
public static boolean isSurrogate(int c)
c
- the character to test
public static boolean isHighSurrogate(int ch)
ch
- The character to test.
public static boolean isLowSurrogate(int ch)
ch
- The character to test.
public static boolean containsSurrogates(CharSequence s)
s
- the string to be tested
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |