Class MultiTermsAggregation.Builder
java.lang.Object
org.opensearch.client.util.ObjectBuilderBase
org.opensearch.client.opensearch._types.aggregations.AggregationBase.AbstractBuilder<MultiTermsAggregation.Builder>
org.opensearch.client.opensearch._types.aggregations.BucketAggregationBase.AbstractBuilder<MultiTermsAggregation.Builder>
org.opensearch.client.opensearch._types.aggregations.MultiTermsAggregation.Builder
- All Implemented Interfaces:
CopyableBuilder<MultiTermsAggregation.Builder,,MultiTermsAggregation> MutableBuilder<MultiTermsAggregation.Builder,,MultiTermsAggregation> ObjectBuilder<MultiTermsAggregation>
- Enclosing class:
MultiTermsAggregation
public static class MultiTermsAggregation.Builder
extends BucketAggregationBase.AbstractBuilder<MultiTermsAggregation.Builder>
implements CopyableBuilder<MultiTermsAggregation.Builder,MultiTermsAggregation>
Builder for
MultiTermsAggregation.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aMultiTermsAggregation.API name:collect_modecopy()Create a new builderCopyableBuilderthat is a copy of this one.minDocCount(Integer value) The minimum number of documents in a bucket for it to be returned.API name:orderorder(HistogramOrder value) API name:orderprotected MultiTermsAggregation.Builderself()shardMinDocCount(Integer value) The minimum number of documents in a bucket on each shard for it to be returned.The number of candidate terms produced by each shard.showTermDocCountError(Boolean value) Calculates the doc count error on per term basis.The number of term buckets should be returned out of the overall terms list.Required - The field from which to generate sets of terms.terms(List<MultiTermLookup> list) Required - The field from which to generate sets of terms.terms(MultiTermLookup value, MultiTermLookup... values) Required - The field from which to generate sets of terms.Methods inherited from class org.opensearch.client.opensearch._types.aggregations.AggregationBase.AbstractBuilder
meta, meta, nameMethods inherited from class org.opensearch.client.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _listCopy, _mapCopy, _mapPut, _mapPutAllMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.opensearch.client.util.MutableBuilder
applyMutation
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
copy
Description copied from interface:CopyableBuilderCreate a new builderCopyableBuilderthat is a copy of this one.- Specified by:
copyin interfaceCopyableBuilder<MultiTermsAggregation.Builder,MultiTermsAggregation> - Returns:
- a new builder instance.
-
self
- Specified by:
selfin classAggregationBase.AbstractBuilder<MultiTermsAggregation.Builder>
-
collectMode
@Nonnull public final MultiTermsAggregation.Builder collectMode(@Nullable TermsAggregationCollectMode value) API name:collect_mode -
minDocCount
The minimum number of documents in a bucket for it to be returned.API name:
min_doc_count -
order
API name:order -
order
@Nonnull public final MultiTermsAggregation.Builder order(Function<HistogramOrder.Builder, ObjectBuilder<HistogramOrder>> fn) API name:order -
shardMinDocCount
The minimum number of documents in a bucket on each shard for it to be returned.API name:
shard_min_doc_count -
shardSize
The number of candidate terms produced by each shard. By default,shard_sizewill be automatically estimated based on the number of shards and thesizeparameter.API name:
shard_size -
showTermDocCountError
Calculates the doc count error on per term basis.API name:
show_term_doc_count_error -
size
The number of term buckets should be returned out of the overall terms list.API name:
size -
terms
Required - The field from which to generate sets of terms.API name:
termsAdds all elements of
listtoterms. -
terms
@Nonnull public final MultiTermsAggregation.Builder terms(MultiTermLookup value, MultiTermLookup... values) Required - The field from which to generate sets of terms.API name:
termsAdds one or more values to
terms. -
terms
@Nonnull public final MultiTermsAggregation.Builder terms(Function<MultiTermLookup.Builder, ObjectBuilder<MultiTermLookup>> fn) Required - The field from which to generate sets of terms.API name:
termsAdds a value to
termsusing a builder lambda. -
build
Builds aMultiTermsAggregation.- Specified by:
buildin interfaceObjectBuilder<MultiTermsAggregation>- Throws:
NullPointerException- if some of the required fields are null.
-