NamedWriteable
, Writeable
, ToXContent
, ToXContentFragment
, BaseAggregationBuilder
public class PercentilesAggregationBuilder extends ValuesSourceAggregationBuilder.LeafOnly<ValuesSource.Numeric,PercentilesAggregationBuilder>
AggregationBuilder.CommonFields
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
ValuesSourceAggregationBuilder.LeafOnly<VS extends ValuesSource,AB extends ValuesSourceAggregationBuilder<VS,AB>>
Writeable.Reader<V>, Writeable.Writer<V>
Modifier and Type | Field | Description |
---|---|---|
static ParseField |
COMPRESSION_FIELD |
|
static ParseField |
KEYED_FIELD |
|
static ParseField |
METHOD_FIELD |
|
static java.lang.String |
NAME |
|
static ParseField |
NUMBER_SIGNIFICANT_DIGITS_FIELD |
|
static ParseField |
PERCENTS_FIELD |
metaData
factoriesBuilder, name
EMPTY_PARAMS
config
Modifier | Constructor | Description |
---|---|---|
|
PercentilesAggregationBuilder(java.lang.String name) |
|
|
PercentilesAggregationBuilder(StreamInput in) |
Read from a stream.
|
protected |
PercentilesAggregationBuilder(PercentilesAggregationBuilder clone,
AggregatorFactories.Builder factoriesBuilder,
java.util.Map<java.lang.String,java.lang.Object> metaData) |
Modifier and Type | Method | Description |
---|---|---|
double |
compression() |
Expert: get the compression.
|
PercentilesAggregationBuilder |
compression(double compression) |
Expert: set the compression.
|
protected XContentBuilder |
doXContentBody(XContentBuilder builder,
ToXContent.Params params) |
|
java.lang.String |
getType() |
The name of the type of aggregation built by this builder.
|
protected ValuesSourceAggregatorFactory<ValuesSource.Numeric,?> |
innerBuild(SearchContext context,
ValuesSourceConfig<ValuesSource.Numeric> config,
AggregatorFactory<?> parent,
AggregatorFactories.Builder subFactoriesBuilder) |
|
protected boolean |
innerEquals(java.lang.Object obj) |
|
protected int |
innerHashCode() |
|
protected void |
innerWriteTo(StreamOutput out) |
Write subclass's state to the stream.
|
boolean |
keyed() |
Get whether the XContent response should be keyed
|
PercentilesAggregationBuilder |
keyed(boolean keyed) |
Set whether the XContent response should be keyed
|
PercentilesMethod |
method() |
|
PercentilesAggregationBuilder |
method(PercentilesMethod method) |
|
int |
numberOfSignificantValueDigits() |
Expert: get the number of significant digits in the values.
|
PercentilesAggregationBuilder |
numberOfSignificantValueDigits(int numberOfSignificantValueDigits) |
Expert: set the number of significant digits in the values.
|
static AggregationBuilder |
parse(java.lang.String aggregationName,
XContentParser parser) |
|
double[] |
percentiles() |
Get the values to compute percentiles from.
|
PercentilesAggregationBuilder |
percentiles(double... percents) |
Set the values to compute percentiles from.
|
protected AggregationBuilder |
shallowCopy(AggregatorFactories.Builder factoriesBuilder,
java.util.Map<java.lang.String,java.lang.Object> metaData) |
Create a shallow copy of this builder and replacing
AggregationBuilder.factoriesBuilder and metaData . |
build, equals, getMetaData, getWriteableName, hashCode, setMetaData, subAggregation, subAggregation, toXContent, writeTo
doRewrite, getName, getPipelineAggregations, getSubAggregations, rewrite, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
isFragment
doBuild, doEquals, doHashCode, doWriteTo, field, field, format, format, internalXContent, missing, missing, resolveConfig, script, script, serializeTargetValueType, timeZone, timeZone, valueType, valueType
subAggregations
public static final java.lang.String NAME
public static final ParseField PERCENTS_FIELD
public static final ParseField KEYED_FIELD
public static final ParseField METHOD_FIELD
public static final ParseField COMPRESSION_FIELD
public static final ParseField NUMBER_SIGNIFICANT_DIGITS_FIELD
public PercentilesAggregationBuilder(java.lang.String name)
protected PercentilesAggregationBuilder(PercentilesAggregationBuilder clone, AggregatorFactories.Builder factoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData)
public PercentilesAggregationBuilder(StreamInput in) throws java.io.IOException
java.io.IOException
public static AggregationBuilder parse(java.lang.String aggregationName, XContentParser parser) throws java.io.IOException
java.io.IOException
protected AggregationBuilder shallowCopy(AggregatorFactories.Builder factoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData)
AggregationBuilder
AggregationBuilder.factoriesBuilder
and metaData
.
Used by AggregationBuilder.rewrite(QueryRewriteContext)
.shallowCopy
in class AggregationBuilder
protected void innerWriteTo(StreamOutput out) throws java.io.IOException
ValuesSourceAggregationBuilder
innerWriteTo
in class ValuesSourceAggregationBuilder<ValuesSource.Numeric,PercentilesAggregationBuilder>
java.io.IOException
public PercentilesAggregationBuilder percentiles(double... percents)
public double[] percentiles()
public PercentilesAggregationBuilder keyed(boolean keyed)
public boolean keyed()
public PercentilesAggregationBuilder numberOfSignificantValueDigits(int numberOfSignificantValueDigits)
PercentilesMethod.HDR
.public int numberOfSignificantValueDigits()
PercentilesMethod.HDR
.public PercentilesAggregationBuilder compression(double compression)
PercentilesMethod.TDIGEST
.public double compression()
PercentilesMethod.TDIGEST
.public PercentilesAggregationBuilder method(PercentilesMethod method)
public PercentilesMethod method()
protected ValuesSourceAggregatorFactory<ValuesSource.Numeric,?> innerBuild(SearchContext context, ValuesSourceConfig<ValuesSource.Numeric> config, AggregatorFactory<?> parent, AggregatorFactories.Builder subFactoriesBuilder) throws java.io.IOException
innerBuild
in class ValuesSourceAggregationBuilder<ValuesSource.Numeric,PercentilesAggregationBuilder>
java.io.IOException
protected XContentBuilder doXContentBody(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
doXContentBody
in class ValuesSourceAggregationBuilder<ValuesSource.Numeric,PercentilesAggregationBuilder>
java.io.IOException
protected boolean innerEquals(java.lang.Object obj)
innerEquals
in class ValuesSourceAggregationBuilder<ValuesSource.Numeric,PercentilesAggregationBuilder>
protected int innerHashCode()
innerHashCode
in class ValuesSourceAggregationBuilder<ValuesSource.Numeric,PercentilesAggregationBuilder>
public java.lang.String getType()
BaseAggregationBuilder