Class ValuesSource.Bytes
java.lang.Object
org.elasticsearch.search.aggregations.support.ValuesSource
org.elasticsearch.search.aggregations.support.ValuesSource.Bytes
- Direct Known Subclasses:
ValuesSource.Bytes.FieldData,ValuesSource.Bytes.Script,ValuesSource.Bytes.WithOrdinals,ValuesSource.Bytes.WithScript
- Enclosing class:
- ValuesSource
ValuesSource for fields who's values are best thought of
as byte arrays without any other meaning like
keyword or
ip. Aggregations that operate on these values presume only
that DocValueFormat.format(BytesRef) will correctly convert
the resulting BytesRef into something human readable.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classValuesSourceimplementation for stand alone scripts returning a Bytes valuestatic classSpecialization of ValuesSource.Bytes who's underlying storage de-duplicates its bytes by storing them in a per-leaf sorted lookup table.static classValuesSourcesubclass for Bytes fields with a Value Script appliedNested classes/interfaces inherited from class org.elasticsearch.search.aggregations.support.ValuesSource
ValuesSource.Bytes, ValuesSource.GeoPoint, ValuesSource.Numeric, ValuesSource.Range -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondocsWithValue(org.apache.lucene.index.LeafReaderContext context)Get a "has any values" view into the values.Build a function to prepareRoundings.Methods inherited from class org.elasticsearch.search.aggregations.support.ValuesSource
bytesValues, hasOrdinals, needsScores
-
Constructor Details
-
Bytes
public Bytes()
-
-
Method Details
-
docsWithValue
public DocValueBits docsWithValue(org.apache.lucene.index.LeafReaderContext context) throws IOExceptionDescription copied from class:ValuesSourceGet a "has any values" view into the values. It'll try to pick the "most native" way to check if there are any values, but it builds its own view into the values so if you need any of the actual values its best to use something likeValuesSource.bytesValues(org.apache.lucene.index.LeafReaderContext)orValuesSource.Numeric.doubleValues(org.apache.lucene.index.LeafReaderContext)but if you just need to know if there are any values then use this.- Specified by:
docsWithValuein classValuesSource- Throws:
IOException
-
roundingPreparer
Description copied from class:ValuesSourceBuild a function to prepareRoundings.This returns a Function because auto date histogram will need to call it many times over the course of running the aggregation. Other aggregations should feel free to call it once.
- Specified by:
roundingPreparerin classValuesSource- Throws:
IOException
-