Class BoundedLocalCache.EntryIterator<K,V>

java.lang.Object
com.github.benmanes.caffeine.cache.BoundedLocalCache.EntryIterator<K,V>
All Implemented Interfaces:
Iterator<Map.Entry<K,V>>
Enclosing class:
BoundedLocalCache<K,V>

static final class BoundedLocalCache.EntryIterator<K,V> extends Object implements Iterator<Map.Entry<K,V>>
An adapter to safely externalize the entry iterator.
  • Field Details

    • cache

      final BoundedLocalCache<K,V> cache
    • iterator

      final Iterator<Node<K,V>> iterator
    • now

      final long now
    • key

      @Nullable K key
    • value

      @Nullable V value
    • removalKey

      @Nullable K removalKey
    • next

      @Nullable Node<K,V> next
  • Constructor Details

  • Method Details

    • hasNext

      public boolean hasNext()
      Specified by:
      hasNext in interface Iterator<K>
    • nextKey

      K nextKey()
    • nextValue

      V nextValue()
    • next

      public Map.Entry<K,V> next()
      Specified by:
      next in interface Iterator<K>
    • remove

      public void remove()
      Specified by:
      remove in interface Iterator<K>