public class InternalHistogram<B extends InternalHistogram.Bucket> extends InternalMultiBucketAggregation<InternalHistogram<B>,B> implements Histogram
Histogram
)?Modifier and Type | Class and Description |
---|---|
static class |
InternalHistogram.Bucket |
static class |
InternalHistogram.Factory<B extends InternalHistogram.Bucket> |
InternalMultiBucketAggregation.InternalBucket
InternalAggregation.CommonFields, InternalAggregation.ReduceContext, InternalAggregation.Type
Histogram.Order
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
Modifier and Type | Field and Description |
---|---|
protected java.util.List<B> |
buckets |
protected InternalHistogram.Factory<B> |
factory |
static InternalHistogram.Factory<InternalHistogram.Bucket> |
HISTOGRAM_FACTORY |
metaData, name
EMPTY_PARAMS
getProperty
getMetaData, getName, getProperty, pipelineAggregators, readFrom, readSize, reduce, toXContent, writeSize, writeTo
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getMetaData, getName, getProperty
public static final InternalHistogram.Factory<InternalHistogram.Bucket> HISTOGRAM_FACTORY
protected java.util.List<B extends InternalHistogram.Bucket> buckets
protected InternalHistogram.Factory<B extends InternalHistogram.Bucket> factory
public static void registerStream()
public InternalAggregation.Type type()
type
in class InternalAggregation
InternalAggregation.Type
of this aggregationpublic java.util.List<B> getBuckets()
getBuckets
in interface Histogram
getBuckets
in interface MultiBucketsAggregation
public InternalHistogram.Factory<B> getFactory()
public Rounding getRounding()
public InternalHistogram<B> create(java.util.List<B> buckets)
InternalMultiBucketAggregation
Aggregation
with the same settings as
this Aggregation
and contains the provided buckets.create
in class InternalMultiBucketAggregation<InternalHistogram<B extends InternalHistogram.Bucket>,B extends InternalHistogram.Bucket>
buckets
- the buckets to use in the new Aggregation
Aggregation
public B createBucket(InternalAggregations aggregations, B prototype)
InternalMultiBucketAggregation
InternalMultiBucketAggregation.InternalBucket
using the provided prototype bucket
and aggregations.createBucket
in class InternalMultiBucketAggregation<InternalHistogram<B extends InternalHistogram.Bucket>,B extends InternalHistogram.Bucket>
aggregations
- the aggregations for the new bucketprototype
- the bucket to use as a prototypepublic InternalAggregation doReduce(java.util.List<InternalAggregation> aggregations, InternalAggregation.ReduceContext reduceContext)
doReduce
in class InternalAggregation
protected void doReadFrom(StreamInput in) throws java.io.IOException
doReadFrom
in class InternalAggregation
java.io.IOException
protected static <B extends InternalHistogram.Bucket> InternalHistogram.Factory<B> resolveFactory(java.lang.String factoryType)
protected void doWriteTo(StreamOutput out) throws java.io.IOException
doWriteTo
in class InternalAggregation
java.io.IOException
public XContentBuilder doXContentBody(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
doXContentBody
in class InternalAggregation
java.io.IOException