Package com.ibm.icu.text
Class TransliteratorParser.ParseData
- java.lang.Object
-
- com.ibm.icu.text.TransliteratorParser.ParseData
-
- All Implemented Interfaces:
SymbolTable
- Enclosing class:
- TransliteratorParser
private class TransliteratorParser.ParseData extends java.lang.Object implements SymbolTable
This class implements the SymbolTable interface. It is used during parsing to give UnicodeSet access to variables that have been defined so far. Note that it uses variablesVector, _not_ data.variables.
-
-
Field Summary
-
Fields inherited from interface com.ibm.icu.text.SymbolTable
SYMBOL_REF
-
-
Constructor Summary
Constructors Modifier Constructor Description private
ParseData()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isMatcher(int ch)
Return true if the given character is a matcher standin or a plain character (non standin).boolean
isReplacer(int ch)
Return true if the given character is a replacer standin or a plain character (non standin).char[]
lookup(java.lang.String name)
Implement SymbolTable API.UnicodeMatcher
lookupMatcher(int ch)
Implement SymbolTable API.java.lang.String
parseReference(java.lang.String text, java.text.ParsePosition pos, int limit)
Implement SymbolTable API.
-
-
-
Method Detail
-
lookup
public char[] lookup(java.lang.String name)
Implement SymbolTable API.- Specified by:
lookup
in interfaceSymbolTable
- Parameters:
name
- the symbolic name to lookup- Returns:
- a char array containing the name's value, or null if there is no mapping for s.
-
lookupMatcher
public UnicodeMatcher lookupMatcher(int ch)
Implement SymbolTable API.- Specified by:
lookupMatcher
in interfaceSymbolTable
- Parameters:
ch
- a 32-bit code point from 0 to 0x10FFFF inclusive.- Returns:
- the UnicodeMatcher object represented by the given character, or null if there is no mapping for ch.
-
parseReference
public java.lang.String parseReference(java.lang.String text, java.text.ParsePosition pos, int limit)
Implement SymbolTable API. Parse out a symbol reference name.- Specified by:
parseReference
in interfaceSymbolTable
- Parameters:
text
- the text to parse for the namepos
- on entry, the index of the first character to parse. This is the character following the SYMBOL_REF character. On exit, the index after the last parsed character. If the parse failed, pos is unchanged on exit.limit
- the index after the last character to be parsed.- Returns:
- the parsed name, or null if there is no valid symbolic name at the given position.
-
isMatcher
public boolean isMatcher(int ch)
Return true if the given character is a matcher standin or a plain character (non standin).
-
isReplacer
public boolean isReplacer(int ch)
Return true if the given character is a replacer standin or a plain character (non standin).
-
-