Package org.apache.lucene.index
Class DocValuesFieldUpdates.AbstractIterator
java.lang.Object
org.apache.lucene.search.DocIdSetIterator
org.apache.lucene.index.DocValuesIterator
org.apache.lucene.index.DocValuesFieldUpdates.Iterator
org.apache.lucene.index.DocValuesFieldUpdates.AbstractIterator
- Direct Known Subclasses:
BinaryDocValuesFieldUpdates.Iterator
,NumericDocValuesFieldUpdates.Iterator
- Enclosing class:
- DocValuesFieldUpdates
protected abstract static class DocValuesFieldUpdates.AbstractIterator
extends DocValuesFieldUpdates.Iterator
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final long
private int
private final PagedMutable
private boolean
private long
private final int
Fields inherited from class org.apache.lucene.search.DocIdSetIterator
NO_MORE_DOCS
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) final long
delGen()
Returns delGen for this packet.final int
docID()
Returns the following:-1
ifDocIdSetIterator.nextDoc()
orDocIdSetIterator.advance(int)
were not called yet.(package private) final boolean
hasValue()
Returns true if this doc has a valuefinal int
nextDoc()
Advances to the next document in the set and returns the doc it is currently on, orDocIdSetIterator.NO_MORE_DOCS
if there are no more docs in the set.
NOTE: after the iterator has exhausted you should not call this method, as it may result in unpredicted behavior.protected abstract void
set
(long idx) Called when the iterator moved to the next documentMethods inherited from class org.apache.lucene.index.DocValuesFieldUpdates.Iterator
advance, advanceExact, asBinaryDocValues, asNumericDocValues, binaryValue, cost, longValue
Methods inherited from class org.apache.lucene.search.DocIdSetIterator
all, empty, range, slowAdvance
-
Field Details
-
size
private final int size -
docs
-
idx
private long idx -
doc
private int doc -
delGen
private final long delGen -
hasValue
private boolean hasValue
-
-
Constructor Details
-
AbstractIterator
AbstractIterator(int size, PagedMutable docs, long delGen)
-
-
Method Details
-
nextDoc
public final int nextDoc()Description copied from class:DocIdSetIterator
Advances to the next document in the set and returns the doc it is currently on, orDocIdSetIterator.NO_MORE_DOCS
if there are no more docs in the set.
NOTE: after the iterator has exhausted you should not call this method, as it may result in unpredicted behavior.- Specified by:
nextDoc
in classDocValuesFieldUpdates.Iterator
-
set
protected abstract void set(long idx) Called when the iterator moved to the next document- Parameters:
idx
- the internal index to set the value to
-
docID
public final int docID()Description copied from class:DocIdSetIterator
Returns the following:-1
ifDocIdSetIterator.nextDoc()
orDocIdSetIterator.advance(int)
were not called yet.DocIdSetIterator.NO_MORE_DOCS
if the iterator has exhausted.- Otherwise it should return the doc ID it is currently on.
- Specified by:
docID
in classDocIdSetIterator
-
delGen
final long delGen()Description copied from class:DocValuesFieldUpdates.Iterator
Returns delGen for this packet.- Specified by:
delGen
in classDocValuesFieldUpdates.Iterator
-
hasValue
final boolean hasValue()Description copied from class:DocValuesFieldUpdates.Iterator
Returns true if this doc has a value- Specified by:
hasValue
in classDocValuesFieldUpdates.Iterator
-