Interface ReadOnlyNavigableMap<K,V>

Type Parameters:
K - the key type
V - the value type
All Superinterfaces:
Iterable<Map.Entry<K,V>>, ReadOnlyMap<K,V>, ReadOnlySequencedMap<K,V>, ReadOnlySortedMap<K,V>
All Known Subinterfaces:
ImmutableNavigableMap<K,V>
All Known Implementing Classes:
MutableRedBlackMap, ReadOnlyNavigableMapFacade, RedBlackMap

public interface ReadOnlyNavigableMap<K,V> extends ReadOnlySortedMap<K,V>
A read-only interface to a navigable map. A navigable map is a SortedMap extended with navigation methods returning the closest matches for given search targets.
  • Method Details

    • ceilingEntry

      @Nullable Map.Entry<K,V> ceilingEntry(K k)
      Returns the least entry in this map with a key greater than or equal to the given key, or null if there is no such entry.
      Parameters:
      k - the given key
      Returns:
      ceiling entry or null
    • floorEntry

      @Nullable Map.Entry<K,V> floorEntry(K k)
      Returns the greatest entry in this map with a key less than or equal to the given key, or null if there is no such entry.
      Parameters:
      k - the given key
      Returns:
      floor entry or null
    • higherEntry

      @Nullable Map.Entry<K,V> higherEntry(K k)
      Returns the least entry in this map with a key greater than the given key, or null if there is no such entry.
      Parameters:
      k - the given key
      Returns:
      higher entry or null
    • lowerEntry

      @Nullable Map.Entry<K,V> lowerEntry(K k)
      Returns the greatest entry in this map with a key less than the given key, or null if there is no such entry.
      Parameters:
      k - the given key
      Returns:
      lower entry or null
    • ceilingKey

      default @Nullable K ceilingKey(K k)
      Returns the least entry in this map with a key greater than or equal to the given key, or null if there is no such key.
      Parameters:
      k - the given key
      Returns:
      ceiling key or null
    • floorKey

      default @Nullable K floorKey(K k)
      Returns the greatest key in this map less than or equal to the given key, or null if there is no such key.
      Parameters:
      k - the given key
      Returns:
      floor key or null
    • higherKey

      default @Nullable K higherKey(K k)
      Returns the least key in this map greater than the given key, or null if there is no such key.
      Parameters:
      k - the given key
      Returns:
      higher key or null
    • lowerKey

      default @Nullable K lowerKey(K k)
      Returns the greatest key in this map less than the given key, or null if there is no such key.
      Parameters:
      k - the given key
      Returns:
      lower key or null