Class InternalMax
java.lang.Object
org.opensearch.search.aggregations.InternalAggregation
org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation
org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation.SingleValue
org.opensearch.search.aggregations.metrics.InternalMax
- All Implemented Interfaces:
org.opensearch.core.common.io.stream.NamedWriteable
,org.opensearch.core.common.io.stream.Writeable
,org.opensearch.core.xcontent.ToXContent
,org.opensearch.core.xcontent.ToXContentFragment
,Aggregation
,Max
,NumericMetricsAggregation
,NumericMetricsAggregation.SingleValue
Implementation of max agg
- Opensearch.internal:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation
InternalNumericMetricsAggregation.MultiValue, InternalNumericMetricsAggregation.SingleValue
Nested classes/interfaces inherited from class org.opensearch.search.aggregations.InternalAggregation
InternalAggregation.ReduceContext, InternalAggregation.ReduceContextBuilder
Nested classes/interfaces inherited from interface org.opensearch.search.aggregations.Aggregation
Aggregation.CommonFields
Nested classes/interfaces inherited from interface org.opensearch.search.aggregations.metrics.NumericMetricsAggregation
NumericMetricsAggregation.MultiValue, NumericMetricsAggregation.SingleValue
Nested classes/interfaces inherited from interface org.opensearch.core.xcontent.ToXContent
org.opensearch.core.xcontent.ToXContent.DelegatingMapParams, org.opensearch.core.xcontent.ToXContent.MapParams, org.opensearch.core.xcontent.ToXContent.Params
Nested classes/interfaces inherited from interface org.opensearch.core.common.io.stream.Writeable
org.opensearch.core.common.io.stream.Writeable.Reader<V>, org.opensearch.core.common.io.stream.Writeable.WriteableRegistry, org.opensearch.core.common.io.stream.Writeable.Writer<V>
-
Field Summary
Fields inherited from class org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation
format
Fields inherited from class org.opensearch.search.aggregations.InternalAggregation
metadata, name
Fields inherited from interface org.opensearch.search.aggregations.Aggregation
TYPED_KEYS_DELIMITER
Fields inherited from interface org.opensearch.core.xcontent.ToXContent
EMPTY_PARAMS
-
Constructor Summary
ConstructorDescriptionInternalMax
(String name, double max, DocValueFormat formatter, Map<String, Object> metadata) InternalMax
(org.opensearch.core.common.io.stream.StreamInput in) Read from a stream. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
doWriteTo
(org.opensearch.core.common.io.stream.StreamOutput out) org.opensearch.core.xcontent.XContentBuilder
doXContentBody
(org.opensearch.core.xcontent.XContentBuilder builder, org.opensearch.core.xcontent.ToXContent.Params params) boolean
double
getValue()
The maximum.int
hashCode()
reduce
(List<InternalAggregation> aggregations, InternalAggregation.ReduceContext reduceContext) Reduces the given aggregations to a single one and returns it.double
value()
Methods inherited from class org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation.SingleValue
getProperty, getValueAsString, sortValue
Methods inherited from class org.opensearch.search.aggregations.metrics.InternalNumericMetricsAggregation
mustReduceOnSingleInternalAgg, sortValue
Methods inherited from class org.opensearch.search.aggregations.InternalAggregation
copyWithRewritenBuckets, forEachBucket, getMetadata, getName, getProperty, getType, isMapped, mergePipelineTreeForBWCSerialization, pipelineAggregatorsForBwcSerialization, readSize, reducePipelines, toString, toXContent, writeSize, writeTo
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.opensearch.search.aggregations.Aggregation
getMetadata, getName, getType
Methods inherited from interface org.opensearch.search.aggregations.metrics.NumericMetricsAggregation.SingleValue
getValueAsString
Methods inherited from interface org.opensearch.core.xcontent.ToXContent
toXContent
Methods inherited from interface org.opensearch.core.xcontent.ToXContentFragment
isFragment
-
Constructor Details
-
InternalMax
-
InternalMax
Read from a stream.- Throws:
IOException
-
-
Method Details
-
doWriteTo
- Specified by:
doWriteTo
in classInternalAggregation
- Throws:
IOException
-
getWriteableName
- Specified by:
getWriteableName
in interfaceorg.opensearch.core.common.io.stream.NamedWriteable
-
value
public double value()- Specified by:
value
in interfaceNumericMetricsAggregation.SingleValue
-
getValue
public double getValue()Description copied from interface:Max
The maximum. -
reduce
public InternalMax reduce(List<InternalAggregation> aggregations, InternalAggregation.ReduceContext reduceContext) Description copied from class:InternalAggregation
Reduces the given aggregations to a single one and returns it. In most cases, the assumption will be the all given aggregations are of the same type (the same type as this aggregation). For best efficiency, when implementing, try reusing an existing instance (typically the first in the given list) to save on redundant object construction.- Specified by:
reduce
in classInternalAggregation
- See Also:
-
doXContentBody
public org.opensearch.core.xcontent.XContentBuilder doXContentBody(org.opensearch.core.xcontent.XContentBuilder builder, org.opensearch.core.xcontent.ToXContent.Params params) throws IOException - Specified by:
doXContentBody
in classInternalAggregation
- Throws:
IOException
-
hashCode
public int hashCode()- Overrides:
hashCode
in classInternalNumericMetricsAggregation
-
equals
- Overrides:
equals
in classInternalNumericMetricsAggregation
-