Package gaiasky.util

Class TwoWayHashmap<K,​V>

java.lang.Object
gaiasky.util.TwoWayHashmap<K,​V>
Type Parameters:
K - Key type in forward map, value in backward map
V - Value type in forward map, key in backward map

public class TwoWayHashmap<K,​V> extends Object
Simple two-way hashmap implemented with two maps.
  • Constructor Details

    • TwoWayHashmap

      public TwoWayHashmap()
  • Method Details

    • add

      public void add(K key, V value)
    • getForward

      public V getForward(K key)
    • getBackward

      public K getBackward(V key)
    • containsKey

      public boolean containsKey(K key)
    • containsValue

      public boolean containsValue(V value)
    • removeKey

      public boolean removeKey(K key)
    • removeValue

      public boolean removeValue(V value)