org.freecompany.util.core
Class Pair<T,Y>

java.lang.Object
  extended by org.freecompany.util.core.Pair<T,Y>

public class Pair<T,Y>
extends java.lang.Object

A generically typed and immutable pair of elements.


Field Summary
protected  T one
           
protected  Y two
           
 
Constructor Summary
Pair(T one, Y two)
           
 
Method Summary
 boolean equals(java.lang.Object object)
           
 int hashCode()
           
 T one()
           
 java.lang.String toString()
           
 Y two()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

one

protected final T one

two

protected final Y two
Constructor Detail

Pair

public Pair(T one,
            Y two)
Method Detail

one

public T one()

two

public Y two()

equals

public boolean equals(java.lang.Object object)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object