Class Int2IntHashMap.AbstractIterator

java.lang.Object
org.agrona.collections.Int2IntHashMap.AbstractIterator
Direct Known Subclasses:
Int2IntHashMap.EntryIterator, Int2IntHashMap.KeyIterator, Int2IntHashMap.ValueIterator
Enclosing class:
Int2IntHashMap

abstract class Int2IntHashMap.AbstractIterator extends Object
Base iterator implementation.
  • Field Details

    • isPositionValid

      protected boolean isPositionValid
      Is current position valid.
    • remaining

      private int remaining
    • positionCounter

      private int positionCounter
    • stopCounter

      private int stopCounter
  • Constructor Details

    • AbstractIterator

      AbstractIterator()
  • Method Details

    • reset

      final void reset()
    • keyPosition

      protected final int keyPosition()
      Returns position of the key of the current entry.
      Returns:
      key position.
    • remaining

      public int remaining()
      Number of remaining elements.
      Returns:
      number of remaining elements.
    • hasNext

      public boolean hasNext()
      Check if there are more elements remaining.
      Returns:
      true if remaining > 0.
    • findNext

      protected final void findNext()
      Advance to the next entry.
      Throws:
      NoSuchElementException - if no more entries available.
    • remove

      public void remove()