Module org.apache.lucene.core
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
Fields Modifier and Type Field Description private long
delGen
private int
doc
private PagedMutable
docs
private boolean
hasValue
private long
idx
private int
size
-
Fields inherited from class org.apache.lucene.search.DocIdSetIterator
NO_MORE_DOCS
-
-
Constructor Summary
Constructors Constructor Description AbstractIterator(int size, PagedMutable docs, long delGen)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description (package private) long
delGen()
Returns delGen for this packet.int
docID()
Returns the following:-1
ifDocIdSetIterator.nextDoc()
orDocIdSetIterator.advance(int)
were not called yet.(package private) boolean
hasValue()
Returns true if this doc has a valueint
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 document-
Methods 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 Detail
-
size
private final int size
-
docs
private final PagedMutable docs
-
idx
private long idx
-
doc
private int doc
-
delGen
private final long delGen
-
hasValue
private boolean hasValue
-
-
Constructor Detail
-
AbstractIterator
AbstractIterator(int size, PagedMutable docs, long delGen)
-
-
Method Detail
-
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
-
-