Interface OrderedMap

    • Nested Class Summary

      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Method Summary

      All Methods Instance Methods Abstract Methods Deprecated Methods 
      Modifier and Type Method Description
      java.lang.Object firstKey()
      Deprecated.
      Gets the first key currently in this map.
      java.lang.Object lastKey()
      Deprecated.
      Gets the last key currently in this map.
      java.lang.Object nextKey​(java.lang.Object key)
      Deprecated.
      Gets the next key after the one specified.
      OrderedMapIterator orderedMapIterator()
      Deprecated.
      Obtains an OrderedMapIterator over the map.
      java.lang.Object previousKey​(java.lang.Object key)
      Deprecated.
      Gets the previous key before the one specified.
      • Methods inherited from interface java.util.Map

        clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
    • Method Detail

      • orderedMapIterator

        OrderedMapIterator orderedMapIterator()
        Deprecated.
        Obtains an OrderedMapIterator over the map.

        A ordered map iterator is an efficient way of iterating over maps in both directions.

         BidiMap map = new TreeBidiMap();
         MapIterator it = map.mapIterator();
         while (it.hasNext()) {
           Object key = it.next();
           Object value = it.getValue();
           it.setValue("newValue");
           Object previousKey = it.previous();
         }
         
        Returns:
        a map iterator
      • firstKey

        java.lang.Object firstKey()
        Deprecated.
        Gets the first key currently in this map.
        Returns:
        the first key currently in this map
        Throws:
        java.util.NoSuchElementException - if this map is empty
      • lastKey

        java.lang.Object lastKey()
        Deprecated.
        Gets the last key currently in this map.
        Returns:
        the last key currently in this map
        Throws:
        java.util.NoSuchElementException - if this map is empty
      • nextKey

        java.lang.Object nextKey​(java.lang.Object key)
        Deprecated.
        Gets the next key after the one specified.
        Parameters:
        key - the key to search for next from
        Returns:
        the next key, null if no match or at end
      • previousKey

        java.lang.Object previousKey​(java.lang.Object key)
        Deprecated.
        Gets the previous key before the one specified.
        Parameters:
        key - the key to search for previous from
        Returns:
        the previous key, null if no match or at start