Class ValuesSource
java.lang.Object
org.opensearch.search.aggregations.support.ValuesSource
- Direct Known Subclasses:
ValuesSource.Bytes
,ValuesSource.GeoPoint
,ValuesSource.Numeric
,ValuesSource.Range
Base class for a ValuesSource; the primitive data for an agg
- Opensearch.internal:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Bytes typestatic class
Geo point values sourcestatic class
Numeric values source typestatic class
Range type -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract SortedBinaryDocValues
bytesValues
(org.apache.lucene.index.LeafReaderContext context) Get the currentValuesSource.Bytes.WithScript.BytesValues
.abstract DocValueBits
docsWithValue
(org.apache.lucene.index.LeafReaderContext context) boolean
Check if this values source supports using global ordinalsboolean
Whether this values source needs scores.abstract Function<Rounding,
Rounding.Prepared> roundingPreparer
(org.apache.lucene.index.IndexReader reader) Build a function prepares rounding values to be called many times.
-
Constructor Details
-
ValuesSource
public ValuesSource()
-
-
Method Details
-
bytesValues
public abstract SortedBinaryDocValues bytesValues(org.apache.lucene.index.LeafReaderContext context) throws IOException Get the currentValuesSource.Bytes.WithScript.BytesValues
.- Throws:
IOException
-
docsWithValue
public abstract DocValueBits docsWithValue(org.apache.lucene.index.LeafReaderContext context) throws IOException - Throws:
IOException
-
needsScores
public boolean needsScores()Whether this values source needs scores. -
roundingPreparer
public abstract Function<Rounding,Rounding.Prepared> roundingPreparer(org.apache.lucene.index.IndexReader reader) throws IOException Build a function prepares rounding values to be called many times.This returns a Function because auto date histogram will need to call it many times over the course of running the aggregation.
- Throws:
IOException
-
hasGlobalOrdinals
public boolean hasGlobalOrdinals()Check if this values source supports using global ordinals
-