Class Pair<K,​V>


  • public class Pair<K,​V>
    extends java.lang.Object
    This class is a container for a pair of objects.
    Version:
    1.0, 26.04.2007
    Author:
    Thoralf Rickert
    • Constructor Summary

      Constructors 
      Constructor Description
      Pair()  
      Pair​(K key, V value)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      K getKey()
      Returns the value of key.
      V getValue()
      Returns the value of value.
      void setKey​(K key)
      Sets the value of key.
      void setValue​(V value)
      Sets the value of value.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Pair

        public Pair()
      • Pair

        public Pair​(K key,
                    V value)
    • Method Detail

      • getKey

        public K getKey()
        Returns the value of key.
        Returns:
        Returns key.
      • setKey

        public void setKey​(K key)
        Sets the value of key.
        Parameters:
        key - The value for key.
      • getValue

        public V getValue()
        Returns the value of value.
        Returns:
        Returns value.
      • setValue

        public void setValue​(V value)
        Sets the value of value.
        Parameters:
        value - The value for value.