Interface HistogramFactory
- All Known Implementing Classes:
InternalAutoDateHistogram
,InternalDateHistogram
,InternalHistogram
,InternalVariableWidthHistogram
public interface HistogramFactory
Implemented by histogram aggregations and used by pipeline aggregations to insert buckets.
-
Method Summary
Modifier and TypeMethodDescriptionCreate anInternalAggregation
object that wraps the given buckets.createBucket
(Number key, long docCount, InternalAggregations aggregations) Create aMultiBucketsAggregation.Bucket
object that wraps the given key, document count and aggregations.getKey
(MultiBucketsAggregation.Bucket bucket) Get the key for the given bucket.Given a key returned bygetKey(org.elasticsearch.search.aggregations.bucket.MultiBucketsAggregation.Bucket)
, compute the lowest key that is greater than it.
-
Method Details
-
getKey
Get the key for the given bucket. Date histograms must return the number of millis since Epoch of the bucket key while numeric histograms must return the double value of the key. -
nextKey
Given a key returned bygetKey(org.elasticsearch.search.aggregations.bucket.MultiBucketsAggregation.Bucket)
, compute the lowest key that is greater than it. -
createAggregation
Create anInternalAggregation
object that wraps the given buckets. -
createBucket
MultiBucketsAggregation.Bucket createBucket(Number key, long docCount, InternalAggregations aggregations) Create aMultiBucketsAggregation.Bucket
object that wraps the given key, document count and aggregations.
-