Class HistogramAggregation
java.lang.Object
co.elastic.clients.elasticsearch._types.aggregations.AggregationBase
co.elastic.clients.elasticsearch._types.aggregations.BucketAggregationBase
co.elastic.clients.elasticsearch._types.aggregations.HistogramAggregation
- All Implemented Interfaces:
AggregationVariant
,PivotGroupByVariant
,JsonpSerializable
@JsonpDeserializable
public class HistogramAggregation
extends BucketAggregationBase
implements AggregationVariant, PivotGroupByVariant
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class co.elastic.clients.elasticsearch._types.aggregations.BucketAggregationBase
BucketAggregationBase.AbstractBuilder<BuilderT extends BucketAggregationBase.AbstractBuilder<BuilderT>>
-
Field Summary
Modifier and TypeFieldDescriptionstatic final JsonpDeserializer<HistogramAggregation>
Json deserializer forHistogramAggregation
-
Method Summary
Modifier and TypeMethodDescriptionAggregation variant kind.PivotGroupBy variant kind.final ExtendedBounds<Double>
Enables extending the bounds of the histogram beyond the data itself.final String
field()
The name of the field to aggregate on.final String
format()
API name:format
final ExtendedBounds<Double>
Limits the range of buckets in the histogram.final Double
interval()
The interval for the buckets.final Boolean
keyed()
Iftrue
, returns buckets as a hash instead of an array, keyed by the bucket keys.final Integer
Only returns buckets that havemin_doc_count
number of documents.final Double
missing()
The value to apply to documents that do not have a value.static HistogramAggregation
final Double
offset()
By default, the bucket keys start with 0 and then continue in even spaced steps ofinterval
.final List<NamedValue<SortOrder>>
order()
The sort order of the returned buckets.final Script
script()
API name:script
protected void
serializeInternal
(jakarta.json.stream.JsonGenerator generator, JsonpMapper mapper) protected static void
Methods inherited from class co.elastic.clients.elasticsearch._types.aggregations.BucketAggregationBase
setupBucketAggregationBaseDeserializer
Methods inherited from class co.elastic.clients.elasticsearch._types.aggregations.AggregationBase
meta, name, serialize, setupAggregationBaseDeserializer, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface co.elastic.clients.elasticsearch._types.aggregations.AggregationVariant
_toAggregation
Methods inherited from interface co.elastic.clients.elasticsearch.transform.PivotGroupByVariant
_toPivotGroupBy
-
Field Details
-
_DESERIALIZER
Json deserializer forHistogramAggregation
-
-
Method Details
-
of
public static HistogramAggregation of(Function<HistogramAggregation.Builder, ObjectBuilder<HistogramAggregation>> fn) -
_aggregationKind
Aggregation variant kind.- Specified by:
_aggregationKind
in interfaceAggregationVariant
-
_pivotGroupByKind
PivotGroupBy variant kind.- Specified by:
_pivotGroupByKind
in interfacePivotGroupByVariant
-
extendedBounds
Enables extending the bounds of the histogram beyond the data itself.API name:
extended_bounds
-
hardBounds
Limits the range of buckets in the histogram. It is particularly useful in the case of open data ranges that can result in a very large number of buckets.API name:
hard_bounds
-
field
The name of the field to aggregate on.API name:
field
-
interval
The interval for the buckets. Must be a positive decimal.API name:
interval
-
minDocCount
Only returns buckets that havemin_doc_count
number of documents. By default, the response will fill gaps in the histogram with empty buckets.API name:
min_doc_count
-
missing
The value to apply to documents that do not have a value. By default, documents without a value are ignored.API name:
missing
-
offset
By default, the bucket keys start with 0 and then continue in even spaced steps ofinterval
. The bucket boundaries can be shifted by using theoffset
option.API name:
offset
-
order
The sort order of the returned buckets. By default, the returned buckets are sorted by their key ascending.API name:
order
-
script
API name:script
-
format
API name:format
-
keyed
Iftrue
, returns buckets as a hash instead of an array, keyed by the bucket keys.API name:
keyed
-
serializeInternal
- Overrides:
serializeInternal
in classAggregationBase
-
setupHistogramAggregationDeserializer
protected static void setupHistogramAggregationDeserializer(ObjectDeserializer<HistogramAggregation.Builder> op)
-