T1
- type of first elementT2
- type of second elementpublic class Tuple2<T1,T2>
extends java.lang.Object
Constructor and Description |
---|
Tuple2(T1 value1,
T2 value2)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
T1 |
_1()
Returns the first element of the tuple.
|
T2 |
_2()
Returns the 2nd element of the tuple.
|
static <R,S> Tuple2<R,S> |
create(R r,
S s)
Returns a new instance.
|
boolean |
equals(java.lang.Object obj) |
int |
hashCode() |
java.lang.String |
toString() |
T1 |
value1()
Returns the first element of the tuple.
|
T2 |
value2()
Returns the 2nd element of the tuple.
|
public static <R,S> Tuple2<R,S> create(R r, S s)
R
- type of first elementS
- type of second elementr
- first elements
- second elementpublic T1 value1()
public T1 _1()
public T2 value2()
public T2 _2()
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2016–2020. All rights reserved.