Class TopMetricsAggregation.Builder
java.lang.Object
co.elastic.clients.util.ObjectBuilderBase
co.elastic.clients.util.WithJsonObjectBuilderBase<BuilderT>
co.elastic.clients.elasticsearch._types.aggregations.MetricAggregationBase.AbstractBuilder<TopMetricsAggregation.Builder>
co.elastic.clients.elasticsearch._types.aggregations.TopMetricsAggregation.Builder
- All Implemented Interfaces:
WithJson<TopMetricsAggregation.Builder>,ObjectBuilder<TopMetricsAggregation>
- Enclosing class:
- TopMetricsAggregation
public static class TopMetricsAggregation.Builder
extends MetricAggregationBase.AbstractBuilder<TopMetricsAggregation.Builder>
implements ObjectBuilder<TopMetricsAggregation>
Builder for
TopMetricsAggregation.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds aTopMetricsAggregation.metrics(TopMetricsValue value, TopMetricsValue... values) API name:metricsAPI name:metricsmetrics(List<TopMetricsValue> list) API name:metricsprotected TopMetricsAggregation.Builderself()API name:sizesort(SortOptions value, SortOptions... values) API name:sortAPI name:sortsort(List<SortOptions> list) API name:sortMethods inherited from class co.elastic.clients.elasticsearch._types.aggregations.MetricAggregationBase.AbstractBuilder
field, missing, missing, missing, missing, missing, missing, script, scriptMethods inherited from class co.elastic.clients.util.WithJsonObjectBuilderBase
withJsonMethods inherited from class co.elastic.clients.util.ObjectBuilderBase
_checkSingleUse, _listAdd, _listAddAll, _mapPut, _mapPutAll
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
metrics
API name:metricsAdds all elements of
listtometrics. -
metrics
public final TopMetricsAggregation.Builder metrics(TopMetricsValue value, TopMetricsValue... values) API name:metricsAdds one or more values to
metrics. -
metrics
public final TopMetricsAggregation.Builder metrics(Function<TopMetricsValue.Builder, ObjectBuilder<TopMetricsValue>> fn) API name:metricsAdds a value to
metricsusing a builder lambda. -
size
API name:size -
sort
API name:sortAdds all elements of
listtosort. -
sort
API name:sortAdds one or more values to
sort. -
sort
public final TopMetricsAggregation.Builder sort(Function<SortOptions.Builder, ObjectBuilder<SortOptions>> fn) API name:sortAdds a value to
sortusing a builder lambda. -
self
- Specified by:
selfin classMetricAggregationBase.AbstractBuilder<TopMetricsAggregation.Builder>
-
build
Builds aTopMetricsAggregation.- Specified by:
buildin interfaceObjectBuilder<TopMetricsAggregation>- Throws:
NullPointerException- if some of the required fields are null.
-