Klasse LongObjectImmutablePair<V>

java.lang.Object
speiger.src.collections.longs.misc.pairs.impl.LongObjectImmutablePair<V>
Typparameter:
V - the keyType of elements maintained by this Collection
Alle implementierten Schnittstellen:
LongObjectPair<V>

public class LongObjectImmutablePair<V> extends Object implements LongObjectPair<V>
Mutable Pair Implementation that
  • Konstruktordetails

    • LongObjectImmutablePair

      public LongObjectImmutablePair()
      Default Constructor
    • LongObjectImmutablePair

      public LongObjectImmutablePair(long key, V value)
      Key/Value Constructur
      Parameter:
      key - the key of the Pair
      value - the value of the Pair
  • Methodendetails

    • setLongKey

      public LongObjectPair<V> setLongKey(long key)
      Beschreibung aus Schnittstelle kopiert: LongObjectPair
      Sets the Key of the Pair.
      Angegeben von:
      setLongKey in Schnittstelle LongObjectPair<V>
      Parameter:
      key - the key that should be set.
      Gibt zurück:
      self or a new Pair instance with the new key.
    • getLongKey

      public long getLongKey()
      Angegeben von:
      getLongKey in Schnittstelle LongObjectPair<V>
      Gibt zurück:
      the Key of the Pair
    • setValue

      public LongObjectPair<V> setValue(V value)
      Beschreibung aus Schnittstelle kopiert: LongObjectPair
      Sets the Value of the Pair.
      Angegeben von:
      setValue in Schnittstelle LongObjectPair<V>
      Parameter:
      value - the value that should be set.
      Gibt zurück:
      self or a new Pair instance with the new value.
    • getValue

      public V getValue()
      Angegeben von:
      getValue in Schnittstelle LongObjectPair<V>
      Gibt zurück:
      the Value of the Pair
    • set

      public LongObjectPair<V> set(long key, V value)
      Beschreibung aus Schnittstelle kopiert: LongObjectPair
      Sets key and value of the Pair
      Angegeben von:
      set in Schnittstelle LongObjectPair<V>
      Parameter:
      key - the key that should be set.
      value - the value that should be set.
      Gibt zurück:
      self or a new Pair instance with the new key and value.
    • shallowCopy

      public LongObjectPair<V> shallowCopy()
      Beschreibung aus Schnittstelle kopiert: LongObjectPair
      Clones the Pair if it is mutable.
      Angegeben von:
      shallowCopy in Schnittstelle LongObjectPair<V>
      Gibt zurück:
      a New Mutable Instance if it is mutable
    • equals

      public boolean equals(Object obj)
      Setzt außer Kraft:
      equals in Klasse Object
    • hashCode

      public int hashCode()
      Setzt außer Kraft:
      hashCode in Klasse Object
    • toString

      public String toString()
      Setzt außer Kraft:
      toString in Klasse Object