Class GeoHashGridAggregationBuilder
- java.lang.Object
-
- org.elasticsearch.search.aggregations.AggregationBuilder
-
- org.elasticsearch.search.aggregations.AbstractAggregationBuilder<AB>
-
- org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder<ValuesSource.GeoPoint,GeoGridAggregationBuilder>
-
- org.elasticsearch.search.aggregations.bucket.geogrid.GeoGridAggregationBuilder
-
- org.elasticsearch.search.aggregations.bucket.geogrid.GeoHashGridAggregationBuilder
-
- All Implemented Interfaces:
NamedWriteable,Writeable,ToXContent,ToXContentFragment,BaseAggregationBuilder,MultiBucketAggregationBuilder
public class GeoHashGridAggregationBuilder extends GeoGridAggregationBuilder
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.elasticsearch.search.aggregations.bucket.geogrid.GeoGridAggregationBuilder
GeoGridAggregationBuilder.PrecisionParser
-
Nested classes/interfaces inherited from class org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder
ValuesSourceAggregationBuilder.LeafOnly<VS extends ValuesSource,AB extends ValuesSourceAggregationBuilder<VS,AB>>
-
Nested classes/interfaces inherited from class org.elasticsearch.search.aggregations.AggregationBuilder
AggregationBuilder.CommonFields
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_MAX_NUM_CELLSstatic intDEFAULT_PRECISIONstatic java.lang.StringNAME-
Fields inherited from class org.elasticsearch.search.aggregations.bucket.geogrid.GeoGridAggregationBuilder
precision, requiredSize, shardSize
-
Fields inherited from class org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder
config
-
Fields inherited from class org.elasticsearch.search.aggregations.AbstractAggregationBuilder
metaData
-
Fields inherited from class org.elasticsearch.search.aggregations.AggregationBuilder
factoriesBuilder, name
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description GeoHashGridAggregationBuilder(java.lang.String name)GeoHashGridAggregationBuilder(StreamInput in)
-
Method Summary
Modifier and Type Method Description protected ValuesSourceAggregatorFactory<ValuesSource.GeoPoint,?>createFactory(java.lang.String name, ValuesSourceConfig<ValuesSource.GeoPoint> config, int precision, int requiredSize, int shardSize, SearchContext context, AggregatorFactory<?> parent, AggregatorFactories.Builder subFactoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData)Creates a new instance of theValuesSourceAggregatorFactory-derived class specific to the geo aggregation.java.lang.StringgetType()The name of the type of aggregation built by this builder.static GeoGridAggregationBuilderparse(java.lang.String aggregationName, XContentParser parser)GeoGridAggregationBuilderprecision(int precision)method to validate and set the precision valueprotected AggregationBuildershallowCopy(AggregatorFactories.Builder factoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData)Create a shallow copy of this builder and replacingAggregationBuilder.factoriesBuilderandmetaData.-
Methods inherited from class org.elasticsearch.search.aggregations.bucket.geogrid.GeoGridAggregationBuilder
createParser, doXContentBody, equals, hashCode, innerBuild, innerWriteTo, precision, shardSize, shardSize, size, size
-
Methods inherited from class org.elasticsearch.search.aggregations.support.ValuesSourceAggregationBuilder
doBuild, doWriteTo, field, field, format, format, internalXContent, missing, missing, resolveConfig, script, script, serializeTargetValueType, timeZone, timeZone, valueType, valueType
-
Methods inherited from class org.elasticsearch.search.aggregations.AbstractAggregationBuilder
build, getMetaData, getWriteableName, setMetaData, subAggregation, subAggregation, subAggregations, toXContent, writeTo
-
Methods inherited from class org.elasticsearch.search.aggregations.AggregationBuilder
doRewrite, getName, getPipelineAggregations, getSubAggregations, rewrite, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentFragment
isFragment
-
-
-
-
Field Detail
-
NAME
public static final java.lang.String NAME
- See Also:
- Constant Field Values
-
DEFAULT_PRECISION
public static final int DEFAULT_PRECISION
- See Also:
- Constant Field Values
-
DEFAULT_MAX_NUM_CELLS
public static final int DEFAULT_MAX_NUM_CELLS
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
GeoHashGridAggregationBuilder
public GeoHashGridAggregationBuilder(java.lang.String name)
-
GeoHashGridAggregationBuilder
public GeoHashGridAggregationBuilder(StreamInput in) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
precision
public GeoGridAggregationBuilder precision(int precision)
Description copied from class:GeoGridAggregationBuildermethod to validate and set the precision value- Specified by:
precisionin classGeoGridAggregationBuilder- Parameters:
precision- the precision to set for the aggregation- Returns:
- the
GeoGridAggregationBuilderbuilder
-
createFactory
protected ValuesSourceAggregatorFactory<ValuesSource.GeoPoint,?> createFactory(java.lang.String name, ValuesSourceConfig<ValuesSource.GeoPoint> config, int precision, int requiredSize, int shardSize, SearchContext context, AggregatorFactory<?> parent, AggregatorFactories.Builder subFactoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData) throws java.io.IOException
Description copied from class:GeoGridAggregationBuilderCreates a new instance of theValuesSourceAggregatorFactory-derived class specific to the geo aggregation.- Specified by:
createFactoryin classGeoGridAggregationBuilder- Throws:
java.io.IOException
-
shallowCopy
protected AggregationBuilder shallowCopy(AggregatorFactories.Builder factoriesBuilder, java.util.Map<java.lang.String,java.lang.Object> metaData)
Description copied from class:AggregationBuilderCreate a shallow copy of this builder and replacingAggregationBuilder.factoriesBuilderandmetaData. Used byAggregationBuilder.rewrite(QueryRewriteContext).- Specified by:
shallowCopyin classAggregationBuilder
-
parse
public static GeoGridAggregationBuilder parse(java.lang.String aggregationName, XContentParser parser) throws java.io.IOException
- Throws:
java.io.IOException
-
getType
public java.lang.String getType()
Description copied from interface:BaseAggregationBuilderThe name of the type of aggregation built by this builder.
-
-