public final class CardinalityAggregationBuilder extends ValuesSourceAggregationBuilder.LeafOnly<ValuesSource,CardinalityAggregationBuilder>
ValuesSourceAggregationBuilder.LeafOnly<VS extends ValuesSource,AB extends ValuesSourceAggregationBuilder<VS,AB>>AggregationBuilder.CommonFieldsWriteable.Reader<V>, Writeable.Writer<V>ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
NAME |
static ParseField |
PRECISION_THRESHOLD_FIELD |
configmetaDatafactoriesBuilder, nameEMPTY_PARAMS| Constructor and Description |
|---|
CardinalityAggregationBuilder(StreamInput in)
Read from a stream.
|
CardinalityAggregationBuilder(java.lang.String name,
ValueType targetValueType) |
| Modifier and Type | Method and Description |
|---|---|
XContentBuilder |
doXContentBody(XContentBuilder builder,
ToXContent.Params params) |
java.lang.String |
getType()
The name of the type of aggregation built by this builder.
|
protected CardinalityAggregatorFactory |
innerBuild(SearchContext context,
ValuesSourceConfig<ValuesSource> 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.
|
static AggregationBuilder |
parse(java.lang.String aggregationName,
XContentParser parser) |
java.lang.Long |
precisionThreshold()
Get the precision threshold.
|
CardinalityAggregationBuilder |
precisionThreshold(long precisionThreshold)
Set a precision threshold.
|
void |
rehash(boolean rehash)
Deprecated.
no replacement - values will always be rehashed
|
protected boolean |
serializeTargetValueType()
Should this builder serialize its targetValueType? Defaults to false.
|
subAggregationsdoBuild, doEquals, doHashCode, doWriteTo, field, field, format, format, internalXContent, missing, missing, resolveConfig, script, script, timeZone, timeZone, valueType, valueTypebuild, equals, getMetaData, getWriteableName, hashCode, setMetaData, subAggregation, subAggregation, toXContent, writeTodoRewrite, getName, getPipelineAggregations, getSubAggregations, rewrite, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitisFragmentpublic static final java.lang.String NAME
public static final ParseField PRECISION_THRESHOLD_FIELD
public CardinalityAggregationBuilder(java.lang.String name,
ValueType targetValueType)
public CardinalityAggregationBuilder(StreamInput in) throws java.io.IOException
java.io.IOExceptionpublic static AggregationBuilder parse(java.lang.String aggregationName, XContentParser parser) throws java.io.IOException
java.io.IOExceptionprotected void innerWriteTo(StreamOutput out) throws java.io.IOException
ValuesSourceAggregationBuilderinnerWriteTo in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>java.io.IOExceptionprotected boolean serializeTargetValueType()
ValuesSourceAggregationBuilderserializeTargetValueType in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>public CardinalityAggregationBuilder precisionThreshold(long precisionThreshold)
public java.lang.Long precisionThreshold()
null if the
precisionThreshold has not been set yet.@Deprecated public void rehash(boolean rehash)
protected CardinalityAggregatorFactory innerBuild(SearchContext context, ValuesSourceConfig<ValuesSource> config, AggregatorFactory<?> parent, AggregatorFactories.Builder subFactoriesBuilder) throws java.io.IOException
innerBuild in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>java.io.IOExceptionpublic XContentBuilder doXContentBody(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
doXContentBody in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>java.io.IOExceptionprotected int innerHashCode()
innerHashCode in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>protected boolean innerEquals(java.lang.Object obj)
innerEquals in class ValuesSourceAggregationBuilder<ValuesSource,CardinalityAggregationBuilder>public java.lang.String getType()
BaseAggregationBuilder