Module org.apache.lucene.core
Package org.apache.lucene.search
Class TimeLimitingKnnCollectorManager
java.lang.Object
org.apache.lucene.search.TimeLimitingKnnCollectorManager
- All Implemented Interfaces:
KnnCollectorManager
A
KnnCollectorManager that collects results with a timeout.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) class -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionTimeLimitingKnnCollectorManager(KnnCollectorManager delegate, QueryTimeout timeout) -
Method Summary
Modifier and TypeMethodDescriptionGet the configuredQueryTimeoutfor terminating graph and exact searches.newCollector(int visitedLimit, LeafReaderContext context) Return a newKnnCollectorinstance.
-
Field Details
-
delegate
-
queryTimeout
-
-
Constructor Details
-
TimeLimitingKnnCollectorManager
-
-
Method Details
-
getQueryTimeout
Get the configuredQueryTimeoutfor terminating graph and exact searches. -
newCollector
Description copied from interface:KnnCollectorManagerReturn a newKnnCollectorinstance.- Specified by:
newCollectorin interfaceKnnCollectorManager- Parameters:
visitedLimit- the maximum number of nodes that the search is allowed to visitcontext- the leaf reader context- Throws:
IOException
-