Class GeoHashGridAggregation.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch._types.aggregations.AggregationBase.AbstractBuilder<BuilderT>
co.elastic.clients.elasticsearch._types.aggregations.BucketAggregationBase.AbstractBuilder<GeoHashGridAggregation.Builder>
co.elastic.clients.elasticsearch._types.aggregations.GeoHashGridAggregation.Builder
- All Implemented Interfaces:
WithJson<GeoHashGridAggregation.Builder>
,ObjectBuilder<GeoHashGridAggregation>
- Enclosing class:
- GeoHashGridAggregation
public static class GeoHashGridAggregation.Builder
extends BucketAggregationBase.AbstractBuilder<GeoHashGridAggregation.Builder>
implements ObjectBuilder<GeoHashGridAggregation>
Builder for
GeoHashGridAggregation
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionThe bounding box to filter the points in each bucket.The bounding box to filter the points in each bucket.build()
Builds aGeoHashGridAggregation
.Field containing indexedgeo_point
orgeo_shape
values.precision
(GeoHashPrecision value) The string length of the geohashes used to define cells/buckets in the results.The string length of the geohashes used to define cells/buckets in the results.protected GeoHashGridAggregation.Builder
self()
Allows for more accurate counting of the top cells returned in the final result the aggregation.The maximum number of geohash buckets to return.Methods inherited from class co.elastic.clients.elasticsearch._types.aggregations.AggregationBase.AbstractBuilder
meta, meta, name
Methods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJson
Methods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
bounds
The bounding box to filter the points in each bucket.API name:
bounds
-
bounds
public final GeoHashGridAggregation.Builder bounds(Function<GeoBounds.Builder, ObjectBuilder<GeoBounds>> fn) The bounding box to filter the points in each bucket.API name:
bounds
-
field
Field containing indexedgeo_point
orgeo_shape
values. If the field contains an array,geohash_grid
aggregates all array values.API name:
field
-
precision
The string length of the geohashes used to define cells/buckets in the results.API name:
precision
-
precision
public final GeoHashGridAggregation.Builder precision(Function<GeoHashPrecision.Builder, ObjectBuilder<GeoHashPrecision>> fn) The string length of the geohashes used to define cells/buckets in the results.API name:
precision
-
shardSize
Allows for more accurate counting of the top cells returned in the final result the aggregation. Defaults to returningmax(10,(size x number-of-shards))
buckets from each shard.API name:
shard_size
-
size
The maximum number of geohash buckets to return.API name:
size
-
self
- Specified by:
self
in classAggregationBase.AbstractBuilder<GeoHashGridAggregation.Builder>
-
build
Builds aGeoHashGridAggregation
.- Specified by:
build
in interfaceObjectBuilder<GeoHashGridAggregation>
- Throws:
NullPointerException
- if some of the required fields are null.
-