public class TermSecondPassGroupingCollector extends AbstractSecondPassGroupingCollector<BytesRef>
AbstractSecondPassGroupingCollector that groups based on
field values and more specifically uses SortedDocValues
to collect grouped docs.AbstractSecondPassGroupingCollector.SearchGroupDocs<GROUP_VALUE_TYPE>groupDocs, groupMap| Constructor and Description |
|---|
TermSecondPassGroupingCollector(String groupField,
Collection<SearchGroup<BytesRef>> groups,
Sort groupSort,
Sort withinGroupSort,
int maxDocsPerGroup,
boolean getScores,
boolean getMaxScores,
boolean fillSortFields) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
doSetNextReader(LeafReaderContext readerContext) |
boolean |
needsScores() |
protected AbstractSecondPassGroupingCollector.SearchGroupDocs<BytesRef> |
retrieveGroup(int doc)
Returns the group the specified doc belongs to or
null if no group could be retrieved. |
collect, getTopGroups, setScorergetLeafCollectorpublic TermSecondPassGroupingCollector(String groupField, Collection<SearchGroup<BytesRef>> groups, Sort groupSort, Sort withinGroupSort, int maxDocsPerGroup, boolean getScores, boolean getMaxScores, boolean fillSortFields) throws IOException
IOExceptionprotected void doSetNextReader(LeafReaderContext readerContext) throws IOException
doSetNextReader in class AbstractSecondPassGroupingCollector<BytesRef>IOExceptionprotected AbstractSecondPassGroupingCollector.SearchGroupDocs<BytesRef> retrieveGroup(int doc) throws IOException
AbstractSecondPassGroupingCollectornull if no group could be retrieved.retrieveGroup in class AbstractSecondPassGroupingCollector<BytesRef>doc - The specified docnull if no group could be retrievedIOException - If an I/O related error occurredpublic boolean needsScores()
Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.