Class 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.
    • 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.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ParseData

        private ParseData()
    • Method Detail

      • lookup

        public char[] lookup​(java.lang.String name)
        Implement SymbolTable API.
        Specified by:
        lookup in interface SymbolTable
        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 interface SymbolTable
        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 interface SymbolTable
        Parameters:
        text - the text to parse for the name
        pos - 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).