org.apache.lucene.util.fst
Class Util.TopNSearcher<T>
java.lang.Object
org.apache.lucene.util.fst.Util.TopNSearcher<T>
- Enclosing class:
- Util
public static class Util.TopNSearcher<T>
- extends Object
Utility class to find top N shortest paths from start
point(s).
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Util.TopNSearcher
public Util.TopNSearcher(FST<T> fst,
int topN,
int maxQueueDepth,
Comparator<T> comparator)
addStartPaths
public void addStartPaths(FST.Arc<T> node,
T startOutput,
boolean allowEmptyString,
IntsRef input)
throws IOException
- Adds all leaving arcs, including 'finished' arc, if
the node is final, from this node into the queue.
- Throws:
IOException
search
public Util.MinResult<T>[] search()
throws IOException
- Throws:
IOException
acceptResult
protected boolean acceptResult(IntsRef input,
T output)
Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.