Class AggregatorFactories
- java.lang.Object
-
- org.elasticsearch.search.aggregations.AggregatorFactories
-
public class AggregatorFactories extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AggregatorFactories.AggParseContext
Context to parse and aggregation.static class
AggregatorFactories.Builder
-
Field Summary
Fields Modifier and Type Field Description static AggregatorFactories
EMPTY
static java.util.regex.Pattern
VALID_AGG_NAME
-
Method Summary
Modifier and Type Method Description static AggregatorFactories.Builder
builder()
int
countAggregators()
int
countPipelineAggregators()
java.util.List<PipelineAggregator>
createPipelineAggregators()
Aggregator[]
createSubAggregators(Aggregator parent)
Create all aggregators so that they can be consumed with multiple buckets.Aggregator[]
createTopLevelAggregators()
static AggregatorFactories.Builder
parseAggregators(XContentParser parser)
Parses the aggregation request recursively generating aggregator factories in turn.
-
-
-
Field Detail
-
VALID_AGG_NAME
public static final java.util.regex.Pattern VALID_AGG_NAME
-
EMPTY
public static final AggregatorFactories EMPTY
-
-
Method Detail
-
parseAggregators
public static AggregatorFactories.Builder parseAggregators(XContentParser parser) throws java.io.IOException
Parses the aggregation request recursively generating aggregator factories in turn.- Throws:
java.io.IOException
-
builder
public static AggregatorFactories.Builder builder()
-
createPipelineAggregators
public java.util.List<PipelineAggregator> createPipelineAggregators()
-
createSubAggregators
public Aggregator[] createSubAggregators(Aggregator parent) throws java.io.IOException
Create all aggregators so that they can be consumed with multiple buckets.- Throws:
java.io.IOException
-
createTopLevelAggregators
public Aggregator[] createTopLevelAggregators() throws java.io.IOException
- Throws:
java.io.IOException
-
countAggregators
public int countAggregators()
- Returns:
- the number of sub-aggregator factories not including pipeline aggregator factories
-
countPipelineAggregators
public int countPipelineAggregators()
- Returns:
- the number of pipeline aggregator factories
-
-