T
- //the first object's typeS
- //the second object's typepublic class Pair<T,S> extends Object
Modifier and Type | Field and Description |
---|---|
private T |
first
the first object of the pair
|
private S |
second
the second object of the pair
|
Constructor and Description |
---|
Pair(Pair<T,S> x)
a constructor that copy's another pair
|
Pair(T newFirst,
S newSecond)
a constructor for this class
|
private T first
private S second
public Pair(T newFirst, S newSecond)
newFirst
- the first object (could be null)newSecond
- the second object (could be null)