Klasse CharObjectImmutablePair<V>

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

public class CharObjectImmutablePair<V> extends Object implements CharObjectPair<V>
Mutable Pair Implementation that
  • Konstruktordetails

    • CharObjectImmutablePair

      public CharObjectImmutablePair()
      Default Constructor
    • CharObjectImmutablePair

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

    • setCharKey

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

      public char getCharKey()
      Angegeben von:
      getCharKey in Schnittstelle CharObjectPair<V>
      Gibt zurück:
      the Key of the Pair
    • setValue

      public CharObjectPair<V> setValue(V value)
      Beschreibung aus Schnittstelle kopiert: CharObjectPair
      Sets the Value of the Pair.
      Angegeben von:
      setValue in Schnittstelle CharObjectPair<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 CharObjectPair<V>
      Gibt zurück:
      the Value of the Pair
    • set

      public CharObjectPair<V> set(char key, V value)
      Beschreibung aus Schnittstelle kopiert: CharObjectPair
      Sets key and value of the Pair
      Angegeben von:
      set in Schnittstelle CharObjectPair<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 CharObjectPair<V> shallowCopy()
      Beschreibung aus Schnittstelle kopiert: CharObjectPair
      Clones the Pair if it is mutable.
      Angegeben von:
      shallowCopy in Schnittstelle CharObjectPair<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