Class SortedNumericDVIndexFieldData
java.lang.Object
org.elasticsearch.index.fielddata.plain.DocValuesIndexFieldData
org.elasticsearch.index.fielddata.plain.SortedNumericDVIndexFieldData
- All Implemented Interfaces:
IndexFieldData<AtomicNumericFieldData>
,IndexNumericFieldData
,IndexComponent
public class SortedNumericDVIndexFieldData extends DocValuesIndexFieldData implements IndexNumericFieldData
FieldData backed by
LeafReader.getSortedNumericDocValues(String)
- See Also:
DocValuesType.SORTED_NUMERIC
-
Nested Class Summary
Nested Classes Modifier and Type Class Description class
SortedNumericDVIndexFieldData.NanoSecondFieldData
A small helper class that can be configured to load nanosecond field data either in nanosecond resolution retaining the original values or in millisecond resolution converting the nanosecond values to millisecondsNested classes/interfaces inherited from class org.elasticsearch.index.fielddata.plain.DocValuesIndexFieldData
DocValuesIndexFieldData.Builder
Nested classes/interfaces inherited from interface org.elasticsearch.index.fielddata.IndexFieldData
IndexFieldData.Builder, IndexFieldData.Global<FD extends AtomicFieldData>, IndexFieldData.XFieldComparatorSource
Nested classes/interfaces inherited from interface org.elasticsearch.index.fielddata.IndexNumericFieldData
IndexNumericFieldData.NumericType
-
Field Summary
Fields inherited from class org.elasticsearch.index.fielddata.plain.DocValuesIndexFieldData
fieldName, index
-
Constructor Summary
Constructors Constructor Description SortedNumericDVIndexFieldData(Index index, java.lang.String fieldNames, IndexNumericFieldData.NumericType numericType)
-
Method Summary
Modifier and Type Method Description IndexNumericFieldData.NumericType
getNumericType()
AtomicNumericFieldData
load(org.apache.lucene.index.LeafReaderContext context)
Loads the atomic field data for the reader, possibly cached.AtomicNumericFieldData
loadDirect(org.apache.lucene.index.LeafReaderContext context)
Loads directly the atomic field data for the reader, ignoring any caching involved.org.apache.lucene.search.SortField
sortField(java.lang.Object missingValue, MultiValueMode sortMode, IndexFieldData.XFieldComparatorSource.Nested nested, boolean reverse)
Returns theSortField
to use for sorting.org.apache.lucene.search.SortField
sortField(IndexNumericFieldData.NumericType targetNumericType, java.lang.Object missingValue, MultiValueMode sortMode, IndexFieldData.XFieldComparatorSource.Nested nested, boolean reverse)
Returns theSortField
to used for sorting.Methods inherited from class org.elasticsearch.index.fielddata.plain.DocValuesIndexFieldData
clear, clear, getFieldName, index
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.elasticsearch.index.fielddata.IndexFieldData
clear, getFieldName
-
Constructor Details
-
SortedNumericDVIndexFieldData
public SortedNumericDVIndexFieldData(Index index, java.lang.String fieldNames, IndexNumericFieldData.NumericType numericType)
-
-
Method Details
-
sortField
public org.apache.lucene.search.SortField sortField(IndexNumericFieldData.NumericType targetNumericType, java.lang.Object missingValue, MultiValueMode sortMode, IndexFieldData.XFieldComparatorSource.Nested nested, boolean reverse)Returns theSortField
to used for sorting. Values are casted to the providedtargetNumericType
type if it doesn't match the field'snumericType
. -
sortField
public org.apache.lucene.search.SortField sortField(java.lang.Object missingValue, MultiValueMode sortMode, IndexFieldData.XFieldComparatorSource.Nested nested, boolean reverse)Description copied from interface:IndexFieldData
Returns theSortField
to use for sorting.- Specified by:
sortField
in interfaceIndexFieldData<AtomicNumericFieldData>
-
getNumericType
- Specified by:
getNumericType
in interfaceIndexNumericFieldData
-
loadDirect
public AtomicNumericFieldData loadDirect(org.apache.lucene.index.LeafReaderContext context) throws java.lang.ExceptionDescription copied from interface:IndexFieldData
Loads directly the atomic field data for the reader, ignoring any caching involved.- Specified by:
loadDirect
in interfaceIndexFieldData<AtomicNumericFieldData>
- Throws:
java.lang.Exception
-
load
Description copied from interface:IndexFieldData
Loads the atomic field data for the reader, possibly cached.- Specified by:
load
in interfaceIndexFieldData<AtomicNumericFieldData>
-