public class Normalizer extends Object
Modifier and Type | Field and Description |
---|---|
static byte |
C
Normalization Form Selector
|
(package private) static byte |
COMPATIBILITY_MASK
Masks for the form selector
|
(package private) static byte |
COMPOSITION_MASK
Masks for the form selector
|
static byte |
D
Normalization Form Selector
|
static byte |
KC
Normalization Form Selector
|
static byte |
KD
Normalization Form Selector
|
static byte |
NO_ACTION
Normalization Form Selector
|
Constructor and Description |
---|
Normalizer(byte form)
Create a normalizer for a given form.
|
Normalizer(CharSequence formCS)
Create a normalizer for a given form, expressed as a character string
|
Modifier and Type | Method and Description |
---|---|
(package private) boolean |
getExcluded(char ch)
Just accessible for testing.
|
(package private) String |
getRawDecompositionMapping(char ch)
Just accessible for testing.
|
CharSequence |
normalize(CharSequence source)
Normalizes text according to the chosen form
|
static final byte COMPATIBILITY_MASK
static final byte COMPOSITION_MASK
public static final byte D
public static final byte C
public static final byte KD
public static final byte KC
public static final byte NO_ACTION
public Normalizer(byte form)
public Normalizer(CharSequence formCS) throws XPathException
formCS
- the normalization form required: for example "NFC" or "NFD"XPathException
public CharSequence normalize(CharSequence source)
source
- the original text, unnormalizedboolean getExcluded(char ch)
ch
- a characterString getRawDecompositionMapping(char ch)
ch
- a character