public abstract static class BooleanBigListIterators.AbstractIndexBasedBigListIterator extends BooleanBigListIterators.AbstractIndexBasedBigIterator implements it.unimi.dsi.fastutil.booleans.BooleanBigListIterator
As the abstract methods in this class are used in inner loops, it is generally a
good idea to override the class as final as to encourage the JVM to inline
them (or alternatively, override the abstract methods as final).
lastReturned, minPos, pos| Modifier | Constructor and Description |
|---|---|
protected |
AbstractIndexBasedBigListIterator(long minPos,
long initialPos) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(boolean k) |
protected abstract void |
add(long location,
boolean k)
Add the given item at the given index.
|
long |
back(long n) |
boolean |
hasPrevious() |
long |
nextIndex() |
boolean |
previousBoolean() |
long |
previousIndex() |
void |
set(boolean k) |
protected abstract void |
set(long location,
boolean k)
Sets the given item at the given index.
|
forEachRemaining, get, getMaxPos, hasNext, nextBoolean, remove, remove, skip, skipclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitadd, set, skip, skipback, previousprotected AbstractIndexBasedBigListIterator(long minPos,
long initialPos)
protected abstract void add(long location,
boolean k)
This method should also do what is needed to track the change to the BooleanBigListIterators.AbstractIndexBasedBigIterator.getMaxPos().
Usually this is accomplished by having this method call the parent Collection's appropriate add
method, and having BooleanBigListIterators.AbstractIndexBasedBigIterator.getMaxPos() track the parent collection's size.
Do not modify BooleanBigListIterators.AbstractIndexBasedBigIterator.pos in this method; the default #add() method takes care of this.
See BooleanBigListIterators.AbstractIndexBasedBigIterator.pos and #get(int) for discussion on what the location means.
protected abstract void set(long location,
boolean k)
See BooleanBigListIterators.AbstractIndexBasedBigIterator.pos and #get(int) for discussion on what the location means.
public boolean hasPrevious()
hasPrevious in interface it.unimi.dsi.fastutil.BidirectionalIterator<java.lang.Boolean>public boolean previousBoolean()
previousBoolean in interface it.unimi.dsi.fastutil.booleans.BooleanBidirectionalIteratorpublic long nextIndex()
nextIndex in interface it.unimi.dsi.fastutil.BigListIterator<java.lang.Boolean>public long previousIndex()
previousIndex in interface it.unimi.dsi.fastutil.BigListIterator<java.lang.Boolean>public void add(boolean k)
add in interface it.unimi.dsi.fastutil.booleans.BooleanBigListIteratorpublic void set(boolean k)
set in interface it.unimi.dsi.fastutil.booleans.BooleanBigListIteratorpublic long back(long n)
back in interface it.unimi.dsi.fastutil.booleans.BooleanBigListIterator