Class SortedNumericDoubleDocValues
- java.lang.Object
-
- org.apache.lucene.search.DocIdSetIterator
-
- org.hibernate.search.backend.lucene.lowlevel.docvalues.impl.SortedNumericDoubleDocValues
-
- Direct Known Subclasses:
GeoPointDistanceDocValues
public abstract class SortedNumericDoubleDocValues extends org.apache.lucene.search.DocIdSetIteratorClone ofSortedNumericDocValuesfor double values.Copied and adapted from
org.elasticsearch.index.fielddata.SortedNumericDoubleValuesclass of Elasticsearch project.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSortedNumericDoubleDocValues()Sole constructor.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract booleanadvanceExact(int target)Advance the iterator to exactlytargetand return whethertargethas a value.static SortedNumericDoubleDocValuescreate(org.apache.lucene.index.SortedNumericDocValues values, LongToDoubleFunction decoder)abstract intdocValueCount()Retrieves the number of values for the current document.static SortedNumericDoubleDocValuesfromDoubleField(org.apache.lucene.index.SortedNumericDocValues values)static SortedNumericDoubleDocValuesfromFloatField(org.apache.lucene.index.SortedNumericDocValues values)abstract doublenextValue()Iterates to the next value in the current document.static NumericDoubleValuesunwrapSingleton(SortedNumericDoubleDocValues values)
-
-
-
Method Detail
-
advanceExact
public abstract boolean advanceExact(int target) throws IOExceptionAdvance the iterator to exactlytargetand return whethertargethas a value.targetmust be greater than or equal to the current doc ID and must be a valid doc ID, ie. ≥ 0 and <maxDoc.- Parameters:
target- the target- Returns:
- the next value
- Throws:
IOException
-
nextValue
public abstract double nextValue() throws IOExceptionIterates to the next value in the current document. Do not call this more thandocValueCount()times for the document.- Returns:
- next value
- Throws:
IOException
-
docValueCount
public abstract int docValueCount()
Retrieves the number of values for the current document. This must always be greater than zero. It is illegal to call this method afteradvanceExact(int)returnedfalse.- Returns:
- value count
-
fromDoubleField
public static SortedNumericDoubleDocValues fromDoubleField(org.apache.lucene.index.SortedNumericDocValues values)
-
fromFloatField
public static SortedNumericDoubleDocValues fromFloatField(org.apache.lucene.index.SortedNumericDocValues values)
-
unwrapSingleton
public static NumericDoubleValues unwrapSingleton(SortedNumericDoubleDocValues values)
-
create
public static SortedNumericDoubleDocValues create(org.apache.lucene.index.SortedNumericDocValues values, LongToDoubleFunction decoder)
-
-