|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectanl.aida.util.Pair<X,Y>
public class Pair<X,Y>
A simple pair class that represents a tuple with two elements.
This class is not implemented to handle null pair values, however it will accept them.
Field Summary | |
---|---|
private X |
first
|
private int |
hashCode
|
private Y |
second
|
Constructor Summary | |
---|---|
Pair(X first,
Y second)
Constructs this class with the specified first and second values |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
Compares this pair to another object. |
X |
getFirst()
Retrieves the first element in the tuple (first, second). |
Y |
getSecond()
Retrieves the second element in the tuple (first, second). |
int |
hashCode()
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private X first
private Y second
private int hashCode
Constructor Detail |
---|
public Pair(X first, Y second)
first
- the first valuesecond
- the second valueMethod Detail |
---|
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public X getFirst()
public Y getSecond()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |