Package org.apache.lucene.search.knn
Class TopKnnCollectorManager
- java.lang.Object
-
- org.apache.lucene.search.knn.TopKnnCollectorManager
-
- All Implemented Interfaces:
KnnCollectorManager
public class TopKnnCollectorManager extends Object implements KnnCollectorManager
TopKnnCollectorManager responsible for creatingTopKnnCollectorinstances. When concurrency is supported, theBlockingFloatHeapis used to track the global top scores collected across all leaves.
-
-
Constructor Summary
Constructors Constructor Description TopKnnCollectorManager(int k, IndexSearcher indexSearcher)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description KnnCollectornewCollector(int visitedLimit, LeafReaderContext context)Return a newTopKnnCollectorinstance.
-
-
-
Constructor Detail
-
TopKnnCollectorManager
public TopKnnCollectorManager(int k, IndexSearcher indexSearcher)
-
-
Method Detail
-
newCollector
public KnnCollector newCollector(int visitedLimit, LeafReaderContext context) throws IOException
Return a newTopKnnCollectorinstance.- Specified by:
newCollectorin interfaceKnnCollectorManager- Parameters:
visitedLimit- the maximum number of nodes that the search is allowed to visitcontext- the leaf reader context- Throws:
IOException
-
-