Package org.agrona.collections
Class Object2ObjectHashMap.AbstractIterator
- java.lang.Object
-
- org.agrona.collections.Object2ObjectHashMap.AbstractIterator
-
- Direct Known Subclasses:
Object2ObjectHashMap.EntryIterator
,Object2ObjectHashMap.KeyIterator
,Object2ObjectHashMap.ValueIterator
- Enclosing class:
- Object2ObjectHashMap<K,V>
abstract class Object2ObjectHashMap.AbstractIterator extends java.lang.Object
Base iterator impl.
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
isPositionValid
Is position valid.private int
positionCounter
private int
remaining
private int
stopCounter
-
Constructor Summary
Constructors Constructor Description AbstractIterator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
findNext()
Find next element.boolean
hasNext()
Check if there is next element to iterate.(package private) int
keyPosition()
int
remaining()
Return number of remaining elements.void
remove()
(package private) void
reset()
-
-
-
Method Detail
-
reset
final void reset()
-
keyPosition
final int keyPosition()
-
remaining
public int remaining()
Return number of remaining elements.- Returns:
- number of remaining elements.
-
hasNext
public boolean hasNext()
Check if there is next element to iterate.- Returns:
true
ifremaining > 0
.
-
findNext
protected final void findNext()
Find next element.- Throws:
java.util.NoSuchElementException
- if no more elements.
-
remove
public void remove()
-
-