E1
- the type of the first elementE2
- the type of the second elementpublic class Pair<E1,E2> extends Object
Constructor and Description |
---|
Pair(E1 element1,
E2 element2)
This constructor creates a pair of
element1 and element2 . |
Modifier and Type | Method and Description |
---|---|
E1 |
getFirstElement()
This method returns the first element.
|
E2 |
getSecondElement()
This method returns the second element.
|
String |
toString() |