|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.lucene.search.suggest.fst.ExternalRefSorter
public class ExternalRefSorter
Builds and iterates over sequences stored on disk.
Constructor Summary | |
---|---|
ExternalRefSorter(Sort sort)
Will buffer all sequences to a temporary file and then sort (all on-disk). |
Method Summary | |
---|---|
void |
add(BytesRef utf8)
Adds a single suggestion entry (possibly compound with its bucket). |
void |
close()
Removes any written temporary files. |
Comparator<BytesRef> |
getComparator()
|
BytesRefIterator |
iterator()
Sorts the entries added in BytesRefSorter.add(BytesRef) and returns
an iterator over all sorted entries. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ExternalRefSorter(Sort sort) throws IOException
IOException
Method Detail |
---|
public void add(BytesRef utf8) throws IOException
BytesRefSorter
add
in interface BytesRefSorter
IOException
- If an I/O exception occurs.public BytesRefIterator iterator() throws IOException
BytesRefSorter
BytesRefSorter.add(BytesRef)
and returns
an iterator over all sorted entries.
iterator
in interface BytesRefSorter
IOException
- If an I/O exception occurs.public void close() throws IOException
close
in interface Closeable
IOException
public Comparator<BytesRef> getComparator()
getComparator
in interface BytesRefSorter
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |