Class OneToOneMap<L,​R>

  • Type Parameters:
    L - keys on the left
    R - keys on the right
    All Implemented Interfaces:
    Serializable

    public class OneToOneMap<L,​R>
    extends Object
    implements Serializable
    One to one map that allows to get a value for a key and a key for a value in O(1).
    Author:
    jonathanberant
    See Also:
    Serialized Form
    • Constructor Detail

      • OneToOneMap

        public OneToOneMap()
    • Method Detail

      • isEmpty

        public boolean isEmpty()
      • size

        public int size()
      • getLeftAsKey

        public R getLeftAsKey​(L l)
      • getRightAsKey

        public L getRightAsKey​(R r)
      • removeLeftAsKey

        public R removeLeftAsKey​(L l)
      • removeRightAsKey

        public L removeRightAsKey​(R r)
      • valuesLeftAsKey

        public Collection<R> valuesLeftAsKey()
      • valuesRightAsKey

        public Collection<L> valuesRightAsKey()
      • entrySetLeftAsKey

        public Set<Map.Entry<L,​R>> entrySetLeftAsKey()
      • entrySetRightAsKey

        public Set<Map.Entry<R,​L>> entrySetRightAsKey()
      • containsLeftAsKey

        public boolean containsLeftAsKey​(L l)
      • containsRightAsKey

        public boolean containsRightAsKey​(R r)
      • clear

        public void clear()