public interface CollectorManager<C extends Collector,T>
newCollector()which must return a NEW collector which will be used to collect a certain set of leaves.
reduce(Collection)which will be used to reduce the results of individual collections into a meaningful result. This method is only called after all leaves have been fully collected.
|Modifier and Type||Method and Description|
Return a new
Reduce the results of individual collectors into a meaningful result.
C newCollector() throws IOException
Collector. This must return a different instance on each call.
T reduce(Collection<C> collectors) throws IOException
TopDocsCollectorwould compute the
top docsof each collector and then merge them using
TopDocs.merge(int, TopDocs). This method must be called after collection is finished on all provided collectors.
Copyright © 2000-2017 Apache Software Foundation. All Rights Reserved.