Class NavigableMapKvIterator<K extends Comparable<K>,V>

java.lang.Object
com.usatiuk.objects.iterators.ReversibleKvIterator<K,V>
com.usatiuk.objects.iterators.NavigableMapKvIterator<K,V>
Type Parameters:
K - the type of the keys
V - the type of the values
All Implemented Interfaces:
CloseableKvIterator<K,V>, AutoCloseable, Iterator<org.apache.commons.lang3.tuple.Pair<K,V>>

public class NavigableMapKvIterator<K extends Comparable<K>,V> extends ReversibleKvIterator<K,V>
A key-value iterator for a NavigableMap. It allows iterating over the keys and values in a sorted order.
  • Constructor Details

    • NavigableMapKvIterator

      public NavigableMapKvIterator(NavigableMap<K,? extends V> map, IteratorStart start, K key)
      Constructs a NavigableMapKvIterator with the specified map, start type, and start key.
      Parameters:
      map - the map to iterate over
      start - the starting position relative to the startKey
      key - the starting key
  • Method Details