Class CellIdSource
- Direct Known Subclasses:
GeoHashCellIdSource,GeoTileCellIdSource
MultiGeoPointValues to CellIdSource.CellMultiValues
and GeoPointValues to CellIdSource.CellSingleValue-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classClass representing the long-encoded grid-cells belonging to the multi-value geo-doc-values.protected static classClass representing the long-encoded grid-cells belonging to the singleton geo-doc-values.Nested classes/interfaces inherited from class org.elasticsearch.search.aggregations.support.ValuesSource.Numeric
ValuesSource.Numeric.FieldData, ValuesSource.Numeric.Script, ValuesSource.Numeric.WithScriptNested classes/interfaces inherited from class org.elasticsearch.search.aggregations.support.ValuesSource
ValuesSource.Bytes, ValuesSource.GeoPoint, ValuesSource.Numeric, ValuesSource.Range -
Field Summary
FieldsFields inherited from class org.elasticsearch.search.aggregations.support.ValuesSource.Numeric
EMPTY -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCellIdSource(ValuesSource.GeoPoint valuesSource, int precision, GeoBoundingBox geoBoundingBox, LongConsumer circuitBreakerConsumer) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract org.apache.lucene.index.SortedNumericDocValuesboundedCellMultiValues(MultiGeoPointValues values, GeoBoundingBox boundingBox) Generate a bounded iterator of grid-cells for multi-value case.protected abstract org.apache.lucene.index.NumericDocValuesboundedCellSingleValue(GeoPointValues values, GeoBoundingBox boundingBox) Generate a bounded iterator of grid-cells for singleton case.final SortedBinaryDocValuesbytesValues(org.apache.lucene.index.LeafReaderContext ctx) Get a byte array like view into the values.doubleValues(org.apache.lucene.index.LeafReaderContext ctx) Get a double precision floating point view into the values in this leaf.final booleanAre values of this field better represented as a double precision floating point numbers (true) or 64 bit signed numbers (false)?final org.apache.lucene.index.SortedNumericDocValueslongValues(org.apache.lucene.index.LeafReaderContext ctx) Get a 64 bit signed view into the values in this leaf.protected booleanpointInBounds(double lon, double lat) checks if the point is inside the bounding box.protected final intprotected abstract org.apache.lucene.index.SortedNumericDocValuesGenerate an unbounded iterator of grid-cells for multi-value case.protected abstract org.apache.lucene.index.NumericDocValuesGenerate an unbounded iterator of grid-cells for singleton case.Methods inherited from class org.elasticsearch.search.aggregations.support.ValuesSource.Numeric
docsWithValue, roundingPreparerMethods inherited from class org.elasticsearch.search.aggregations.support.ValuesSource
hasOrdinals, needsScores
-
Field Details
-
circuitBreakerConsumer
-
-
Constructor Details
-
CellIdSource
protected CellIdSource(ValuesSource.GeoPoint valuesSource, int precision, GeoBoundingBox geoBoundingBox, LongConsumer circuitBreakerConsumer)
-
-
Method Details
-
precision
protected final int precision() -
isFloatingPoint
public final boolean isFloatingPoint()Description copied from class:ValuesSource.NumericAre values of this field better represented as a double precision floating point numbers (true) or 64 bit signed numbers (false)?Aggregations may, if they feel it is important, use this to pick which of
ValuesSource.Numeric.longValues(org.apache.lucene.index.LeafReaderContext)andValuesSource.Numeric.doubleValues(org.apache.lucene.index.LeafReaderContext)is better for the field values. Most metric aggregations are quite happy to operate on floating point numbers all the time and never call this. Bucketing aggregations that want to enumerate all values (likeTermsAggregator) will want to check this but bucketing aggregations that just compare values (RangeAggregator) are, like metric aggregators, fine ignoring it.- Specified by:
isFloatingPointin classValuesSource.Numeric
-
longValues
public final org.apache.lucene.index.SortedNumericDocValues longValues(org.apache.lucene.index.LeafReaderContext ctx) Description copied from class:ValuesSource.NumericGet a 64 bit signed view into the values in this leaf.If the values have precision beyond the decimal point then they'll be "narrowed" but they'll accurately represent values up to
Long.MAX_VALUE.- Specified by:
longValuesin classValuesSource.Numeric
-
unboundedCellSingleValue
protected abstract org.apache.lucene.index.NumericDocValues unboundedCellSingleValue(GeoPointValues values) Generate an unbounded iterator of grid-cells for singleton case. -
boundedCellSingleValue
protected abstract org.apache.lucene.index.NumericDocValues boundedCellSingleValue(GeoPointValues values, GeoBoundingBox boundingBox) Generate a bounded iterator of grid-cells for singleton case. -
unboundedCellMultiValues
protected abstract org.apache.lucene.index.SortedNumericDocValues unboundedCellMultiValues(MultiGeoPointValues values) Generate an unbounded iterator of grid-cells for multi-value case. -
boundedCellMultiValues
protected abstract org.apache.lucene.index.SortedNumericDocValues boundedCellMultiValues(MultiGeoPointValues values, GeoBoundingBox boundingBox) Generate a bounded iterator of grid-cells for multi-value case. -
doubleValues
Description copied from class:ValuesSource.NumericGet a double precision floating point view into the values in this leaf.These values will preserve any precision beyond the decimal point but are limited to
double's standard 53 bit mantissa. If the "native" field has values that can't be accurately represented in those 53 bits they'll be "widened"- Specified by:
doubleValuesin classValuesSource.Numeric
-
bytesValues
Description copied from class:ValuesSourceGet a byte array like view into the values. This is the "native" way to accessValuesSource.Bytes-style values.- Specified by:
bytesValuesin classValuesSource
-
pointInBounds
protected boolean pointInBounds(double lon, double lat) checks if the point is inside the bounding box. If the method return true, the point should be added to the final result, otherwise implementors might need to check if the point grid intersects the bounding box. This method maybe faster than having to compute the bounding box for each point grid.
-