Class TernaryTree.Iterator
java.lang.Object
org.apache.lucene.analysis.compound.hyphenation.TernaryTree.Iterator
- All Implemented Interfaces:
Enumeration<String>
- Enclosing class:
TernaryTree
Enumeration over TST keys
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescription(package private) int
current node index(package private) String
current key(package private) StringBuilder
key stack implemented with a StringBuilder(package private) Deque
<TernaryTree.Iterator.Item> Node stack -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Enumeration
asIterator
-
Field Details
-
cur
int curcurrent node index -
curkey
String curkeycurrent key -
ns
Node stack -
ks
key stack implemented with a StringBuilder
-
-
Constructor Details
-
Iterator
public Iterator()
-
-
Method Details
-
rewind
public void rewind() -
nextElement
- Specified by:
nextElement
in interfaceEnumeration<String>
-
getValue
public char getValue() -
hasMoreElements
public boolean hasMoreElements()- Specified by:
hasMoreElements
in interfaceEnumeration<String>
-
up
private int up()traverse upwards -
run
private int run()traverse the tree to find next key
-