Collectorwhich allows running a search with several
Collectors. It offers a static
wrap(org.apache.lucene.search.Collector...)method which accepts a list of collectors and wraps them with
MultiCollector, while filtering out the
NOTE:When mixing collectors that want to skip low-scoring hits (
ScoreMode.TOP_SCORES) with ones that require to see all hits, such as mixing
TotalHitCountCollector, it should be faster to run the query
twice, once for each collector, rather than using this wrapper on a single search.
|Modifier and Type||Method and Description|
Create a new
Indicates what features are required from the scorer.
Collectors with a
MultiCollector. This method works as follows:
nullcollectors, so they are not used during search time.
null), it is returned.
MultiCollectorwhich wraps the non-
IllegalArgumentException- if either 0 collectors were input, or all collectors are
public ScoreMode scoreMode()
public LeafCollector getLeafCollector(LeafReaderContext context) throws IOException
collectorto collect the given context.
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.