public class Grouping.CommandField extends Grouping.Command<BytesRef>
| Modifier and Type | Field and Description |
|---|---|
String |
groupBy |
docsPerGroup, format, groupOffset, groupSort, key, main, numGroups, offset, totalCount, withinGroupSort| Constructor and Description |
|---|
CommandField() |
| Modifier and Type | Method and Description |
|---|---|
AllGroupHeadsCollector<?> |
createAllGroupCollector()
Returns a collector that is able to return the most relevant document of all groups.
|
protected Collector |
createFirstPassCollector()
Returns one or more
Collector instances that are needed to perform the first pass search. |
protected Collector |
createSecondPassCollector()
Returns zero or more
Collector instances that are needed to perform the second pass search. |
protected void |
finish()
Performs any necessary post actions to prepare the response.
|
int |
getMatches()
Returns the number of matches for this
Command. |
protected Integer |
getNumberOfGroups()
Returns the number of groups found for this
Command. |
protected void |
prepare()
Prepare this
Command for execution. |
addDocList, commonResponse, createSimpleResponse, getDocListpublic String groupBy
protected void prepare()
throws IOException
Grouping.CommandCommand for execution.prepare in class Grouping.Command<BytesRef>IOException - If I/O related errors occurprotected Collector createFirstPassCollector() throws IOException
Grouping.CommandCollector instances that are needed to perform the first pass search.
If multiple Collectors are returned then these wrapped in a MultiCollector.createFirstPassCollector in class Grouping.Command<BytesRef>Collector instances that are need to perform the first pass searchIOException - If I/O related errors occurprotected Collector createSecondPassCollector() throws IOException
Grouping.CommandCollector instances that are needed to perform the second pass search.
In the case when no Collector instances are created null is returned.
If multiple Collectors are returned then these wrapped in a MultiCollector.createSecondPassCollector in class Grouping.Command<BytesRef>Collector instances that are needed to perform the second pass searchIOException - If I/O related errors occurpublic AllGroupHeadsCollector<?> createAllGroupCollector() throws IOException
Grouping.Commandnull if the command doesn't support this type of collector.createAllGroupCollector in class Grouping.Command<BytesRef>IOException - If I/O related errors occurprotected void finish()
throws IOException
Grouping.Commandfinish in class Grouping.Command<BytesRef>IOException - If I/O related errors occurpublic int getMatches()
Grouping.CommandCommand.getMatches in class Grouping.Command<BytesRef>Commandprotected Integer getNumberOfGroups()
Grouping.CommandCommand.
If the command doesn't support counting the groups null is returned.getNumberOfGroups in class Grouping.Command<BytesRef>CommandCopyright © 2000-2020 Apache Software Foundation. All Rights Reserved.