|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.text.Transliterator | +--com.ibm.text.CompoundTransliterator
A transliterator that is composed of two or more other transliterator objects linked together. For example, if one transliterator transliterates from script A to script B, and another transliterates from script B to script C, the two may be combined to form a new transliterator from A to C.
Composed transliterators may not behave as expected. For
example, inverses may not combine to form the identity
transliterator. See the class documentation for Transliterator
for details.
If a non-null UnicodeFilter is applied to a CompoundTransliterator, it has the effect of being logically anded with the filter of each transliterator in the chain.
Copyright © IBM Corporation 1999. All rights reserved.
Inner classes inherited from class com.ibm.text.Transliterator |
Transliterator.Position |
Fields inherited from class com.ibm.text.Transliterator |
FORWARD, REVERSE |
Constructor Summary | |
CompoundTransliterator(java.lang.String ID)
|
|
CompoundTransliterator(java.lang.String ID,
int direction)
|
|
CompoundTransliterator(java.lang.String ID,
int direction,
UnicodeFilter filter)
Splits an ID of the form "ID;ID;..." into a compound using each of the IDs. |
|
CompoundTransliterator(Transliterator[] transliterators)
Constructs a new compound transliterator given an array of transliterators. |
|
CompoundTransliterator(Transliterator[] transliterators,
UnicodeFilter filter)
Constructs a new compound transliterator given an array of transliterators. |
Method Summary | |
int |
getCount()
Returns the number of transliterators in this chain. |
Transliterator |
getTransliterator(int index)
Returns the transliterator at the given index in this chain. |
protected void |
handleTransliterate(Replaceable text,
Transliterator.Position index,
boolean incremental)
Implements Transliterator.handleTransliterate(com.ibm.text.Replaceable, com.ibm.text.Transliterator.Position, boolean) . |
void |
setFilter(UnicodeFilter f)
Override Transliterator. |
Methods inherited from class com.ibm.text.Transliterator |
filteredCharAt, finishTransliteration, getAvailableIDs, getDisplayName, getDisplayName, getFilter, getID, getInstance, getInstance, getInverse, getMaximumContextLength, registerClass, setMaximumContextLength, transliterate, transliterate, transliterate, transliterate, transliterate, transliterate, unregister |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CompoundTransliterator(Transliterator[] transliterators, UnicodeFilter filter)
transliterators
- array of Transliterator
objectsfilter
- the filter. Any character for which
filter.contains() returns false will not be
altered by this transliterator. If filter is
null then no filtering is applied.public CompoundTransliterator(Transliterator[] transliterators)
transliterators
- array of Transliterator
objectspublic CompoundTransliterator(java.lang.String ID, int direction, UnicodeFilter filter)
ID
- of above formforward
- if false, does the list in reverse order, and
takes the inverse of each ID.public CompoundTransliterator(java.lang.String ID, int direction)
public CompoundTransliterator(java.lang.String ID)
Method Detail |
public int getCount()
public Transliterator getTransliterator(int index)
index
- index into chain, from 0 to getCount() - 1
public void setFilter(UnicodeFilter f)
setFilter
in class Transliterator
protected void handleTransliterate(Replaceable text, Transliterator.Position index, boolean incremental)
Transliterator.handleTransliterate(com.ibm.text.Replaceable, com.ibm.text.Transliterator.Position, boolean)
.handleTransliterate
in class Transliterator
com.ibm.text.Transliterator
text
- the buffer holding transliterated and
untransliterated textpos
- the start and limit of the text, the position
of the cursor, and the start and limit of transliteration.incremental
- if true, assume more text may be coming after
pos.contextLimit. Otherwise, assume the text is complete.Transliterator.transliterate(com.ibm.text.Replaceable, int, int)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |