Class OrderedPair<T>

java.lang.Object
org.biojava.nbio.structure.quaternary.OrderedPair<T>
Type Parameters:
T -

public class OrderedPair<T> extends Object
An ordered pair represents a component of a cartesian product. The cartesian product of two sets A and B is the set of all ordered pairs of the elements of both sets. See http://en.wikipedia.org/wiki/Cartesian_product for more details. Example: A = {1, 2, 3} B = {4, 5} The ordered pairs are {1, 4}, {1, 5}, {2, 4}, .., {3, 5}
Author:
Peter Rose
  • Method Details

    • getElement1

      public T getElement1()
      Returns:
      element1 the first element of an ordered pair
    • setElement1

      public void setElement1(T element1)
      Sets the first element of an ordered pair.
      Parameters:
      element1 - the first element of an ordered pair
    • getElement2

      public T getElement2()
      Returns:
      element2 the second element of an ordered pair
    • setElement2

      public void setElement2(T element2)
      Sets the second element of an ordered pair.
      Parameters:
      element2 - the second element of an ordered pair
    • toString

      public String toString()
      Overrides:
      toString in class Object