Class RuleBasedTransliterator.Data

    • Field Summary

      Fields 
      Modifier and Type Field Description
      TransliterationRuleSet ruleSet
      Rule table.
      (package private) java.util.Map<java.lang.String,​char[]> variableNames
      Map variable name (String) to variable (char[]).
      (package private) java.lang.Object[] variables
      Map category variable (Character) to UnicodeMatcher or UnicodeReplacer.
      (package private) char variablesBase
      The character that represents variables[0].
    • Constructor Summary

      Constructors 
      Constructor Description
      Data()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      UnicodeMatcher lookupMatcher​(int standIn)
      Return the UnicodeMatcher represented by the given character, or null if none.
      UnicodeReplacer lookupReplacer​(int standIn)
      Return the UnicodeReplacer represented by the given character, or null if none.
      • Methods inherited from class java.lang.Object

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

      • variableNames

        java.util.Map<java.lang.String,​char[]> variableNames
        Map variable name (String) to variable (char[]). A variable name corresponds to zero or more characters, stored in a char[] array in this hash. One or more of these chars may also correspond to a UnicodeSet, in which case the character in the char[] in this hash is a stand-in: it is an index for a secondary lookup in data.variables. The stand-in also represents the UnicodeSet in the stored rules.
      • variables

        java.lang.Object[] variables
        Map category variable (Character) to UnicodeMatcher or UnicodeReplacer. Variables that correspond to a set of characters are mapped from variable name to a stand-in character in data.variableNames. The stand-in then serves as a key in this hash to lookup the actual UnicodeSet object. In addition, the stand-in is stored in the rule text to represent the set of characters. variables[i] represents character (variablesBase + i).
      • variablesBase

        char variablesBase
        The character that represents variables[0]. Characters variablesBase through variablesBase + variables.length - 1 represent UnicodeSet objects.
    • Constructor Detail

      • Data

        public Data()
    • Method Detail

      • lookupMatcher

        public UnicodeMatcher lookupMatcher​(int standIn)
        Return the UnicodeMatcher represented by the given character, or null if none.
      • lookupReplacer

        public UnicodeReplacer lookupReplacer​(int standIn)
        Return the UnicodeReplacer represented by the given character, or null if none.