Class SortingNumericDocValues
- java.lang.Object
-
- org.apache.lucene.search.DocIdSetIterator
-
- org.apache.lucene.index.SortedNumericDocValues
-
- org.elasticsearch.index.fielddata.SortingNumericDocValues
-
- Direct Known Subclasses:
AbstractSortingNumericDocValues
public abstract class SortingNumericDocValues extends SortedNumericDocValues
Base class for buildingSortedNumericDocValuesinstances based on unsorted content.
-
-
Field Summary
Fields Modifier and Type Field Description protected long[]valuesprotected intvaluesCursor-
Fields inherited from class org.apache.lucene.search.DocIdSetIterator
NO_MORE_DOCS
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSortingNumericDocValues()
-
Method Summary
All 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.intdocValueCount()Retrieves the number of values for the current document.longnextValue()Iterates to the next value in the current document.protected voidresize(int newSize)Set thedocValueCount()and ensure that thevaluesarray can store at least that many entries.protected voidsort()-
Methods inherited from class org.apache.lucene.search.DocIdSetIterator
advance, all, cost, docID, empty, nextDoc, range, slowAdvance
-
-
-
-
Method Detail
-
resize
protected final void resize(int newSize)
Set thedocValueCount()and ensure that thevaluesarray can store at least that many entries.
-
sort
protected final void sort()
-
docValueCount
public final int docValueCount()
Description copied from class:SortedNumericDocValuesRetrieves 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.- Specified by:
docValueCountin classSortedNumericDocValues
-
nextValue
public final long nextValue()
Description copied from class:SortedNumericDocValuesIterates to the next value in the current document. Do not call this more thanSortedNumericDocValues.docValueCount()times for the document.- Specified by:
nextValuein classSortedNumericDocValues
-
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 currentdoc IDand must be a valid doc ID, ie. ≥ 0 and <maxDoc. After this method returns,DocIdSetIterator.docID()returnstarget.- Throws:
IOException
-
-