org.freecompany.util.core
Class Pair<T,Y>
java.lang.Object
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)
|
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
one
protected final T one
two
protected final Y two
Pair
public Pair(T one,
Y two)
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