Class Pair<T,​E>


  • public class Pair<T,​E>
    extends java.lang.Object
    The type holding a pair of objects.

    Author:
    Erhan Bagdemir
    • Constructor Summary

      Constructors 
      Constructor Description
      Pair​(T first, E second)
      Constructs a Pair instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      T getFirst()
      Getter for the first item.
      E getSecond()
      Getter for the second item.
      • Methods inherited from class java.lang.Object

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

      • Pair

        public Pair​(T first,
                    E second)
        Constructs a Pair instance.

        Parameters:
        first - The first value.
        second - The second value.
    • Method Detail

      • getFirst

        public T getFirst()
        Getter for the first item.

        Returns:
        The first item.
      • getSecond

        public E getSecond()
        Getter for the second item.

        Returns:
        The second item.