Package org.hawaiiframework.util.tuple
Class Tuple2<T1,T2>
java.lang.Object
org.hawaiiframework.util.tuple.Tuple1<T1>
org.hawaiiframework.util.tuple.Tuple2<T1,T2>
- Type Parameters:
T1
- the type of the 1st elementT2
- the type of the 2nd element
- All Implemented Interfaces:
Tuple
- Direct Known Subclasses:
Tuple3
A
Tuple
of 2 elements.- Since:
- 2.0.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Returns the 2nd element of this tuple.int
hashCode()
void
setElement2
(T2 element2) Sets the 2nd element of this tuple.int
size()
Returns the number of elements of this tuple.Methods inherited from class org.hawaiiframework.util.tuple.Tuple1
getElement1, setElement1
-
Constructor Details
-
Tuple2
Constructs a newTuple
with the supplied elements.
-
-
Method Details
-
getElement2
Returns the 2nd element of this tuple.- Returns:
- the 2nd element of this tuple
-
setElement2
Sets the 2nd element of this tuple. -
size
public int size()Description copied from interface:Tuple
Returns the number of elements of this tuple. -
equals
-
hashCode
public int hashCode()
-