Class IpPrefixAggregation.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<IpPrefixAggregation.Builder>
co.elastic.clients.elasticsearch._types.aggregations.IpPrefixAggregation.Builder
- All Implemented Interfaces:
WithJson<IpPrefixAggregation.Builder>
,ObjectBuilder<IpPrefixAggregation>
- Enclosing class:
- IpPrefixAggregation
public static class IpPrefixAggregation.Builder
extends BucketAggregationBase.AbstractBuilder<IpPrefixAggregation.Builder>
implements ObjectBuilder<IpPrefixAggregation>
Builder for
IpPrefixAggregation
.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionappendPrefixLength
(Boolean value) Defines whether the prefix length is appended to IP address keys in the response.build()
Builds aIpPrefixAggregation
.Required - The IP address field to aggregation on.Defines whether the prefix applies to IPv6 addresses.Defines whether buckets are returned as a hash rather than an array in the response.minDocCount
(Long value) Minimum number of documents in a bucket for it to be included in the response.prefixLength
(int value) Required - Length of the network prefix.protected IpPrefixAggregation.Builder
self()
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
-
field
Required - The IP address field to aggregation on. The field mapping type must beip
.API name:
field
-
prefixLength
Required - Length of the network prefix. For IPv4 addresses the accepted range is [0, 32]. For IPv6 addresses the accepted range is [0, 128].API name:
prefix_length
-
isIpv6
Defines whether the prefix applies to IPv6 addresses.API name:
is_ipv6
-
appendPrefixLength
Defines whether the prefix length is appended to IP address keys in the response.API name:
append_prefix_length
-
keyed
Defines whether buckets are returned as a hash rather than an array in the response.API name:
keyed
-
minDocCount
Minimum number of documents in a bucket for it to be included in the response.API name:
min_doc_count
-
self
- Specified by:
self
in classAggregationBase.AbstractBuilder<IpPrefixAggregation.Builder>
-
build
Builds aIpPrefixAggregation
.- Specified by:
build
in interfaceObjectBuilder<IpPrefixAggregation>
- Throws:
NullPointerException
- if some of the required fields are null.
-