Class InternalAggregations
- java.lang.Object
-
- org.elasticsearch.search.aggregations.Aggregations
-
- org.elasticsearch.search.aggregations.InternalAggregations
-
- All Implemented Interfaces:
java.lang.Iterable<Aggregation>,Writeable,ToXContent,ToXContentFragment
public final class InternalAggregations extends Aggregations implements Writeable
An internal implementation ofAggregations.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
Fields Modifier and Type Field Description static InternalAggregationsEMPTY-
Fields inherited from class org.elasticsearch.search.aggregations.Aggregations
aggregations, AGGREGATIONS_FIELD
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description InternalAggregations(java.util.List<InternalAggregation> aggregations)Constructs a new aggregation.InternalAggregations(java.util.List<InternalAggregation> aggregations, java.util.List<SiblingPipelineAggregator> topLevelPipelineAggregators)Constructs a new aggregation providing itsInternalAggregations andSiblingPipelineAggregatorsInternalAggregations(StreamInput in)
-
Method Summary
Modifier and Type Method Description java.util.List<SiblingPipelineAggregator>getTopLevelPipelineAggregators()Returns the top-level pipeline aggregators.static InternalAggregationsreduce(java.util.List<InternalAggregations> aggregationsList, InternalAggregation.ReduceContext context)Reduces the given list of aggregations as well as the top-level pipeline aggregators extracted from the firstInternalAggregationsobject found in the list.voidwriteTo(StreamOutput out)Write this into the StreamOutput.-
Methods inherited from class org.elasticsearch.search.aggregations.Aggregations
asList, asMap, equals, fromXContent, get, getAsMap, hashCode, iterator, toXContent, toXContentInternal
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentFragment
isFragment
-
-
-
-
Field Detail
-
EMPTY
public static final InternalAggregations EMPTY
-
-
Constructor Detail
-
InternalAggregations
public InternalAggregations(java.util.List<InternalAggregation> aggregations)
Constructs a new aggregation.
-
InternalAggregations
public InternalAggregations(java.util.List<InternalAggregation> aggregations, java.util.List<SiblingPipelineAggregator> topLevelPipelineAggregators)
Constructs a new aggregation providing itsInternalAggregations andSiblingPipelineAggregators
-
InternalAggregations
public InternalAggregations(StreamInput in) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:WriteableWrite this into the StreamOutput.
-
getTopLevelPipelineAggregators
public java.util.List<SiblingPipelineAggregator> getTopLevelPipelineAggregators()
Returns the top-level pipeline aggregators. Note that top-level pipeline aggregators become normal aggregation once the final reduction has been performed, after which they become part of the list ofInternalAggregations.
-
reduce
public static InternalAggregations reduce(java.util.List<InternalAggregations> aggregationsList, InternalAggregation.ReduceContext context)
Reduces the given list of aggregations as well as the top-level pipeline aggregators extracted from the firstInternalAggregationsobject found in the list. Note that top-level pipeline aggregators are reduced only as part of the final reduction phase, otherwise they are left untouched.
-
-