| Modifier and Type | Field and Description |
|---|---|
| public final T1 | _1
The 1st element of this tuple. |
| public final T2 | _2
The 2nd element of this tuple. |
| private static final long |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public T1 | |
| public T2 | |
| public < type of the value to append T3> Tuple3 | Returns: a new Tuple with the value appendedthe value to append t3)Append a value to this tuple. |
| public < type of the transformation result U> U | Returns: An object of type UTransformation which creates a new object of type U based on this tuple's contents. f)Transforms this tuple to an object of type U. |
| public int | |
| public static <T1, T2> Comparator | |
| private static <U1 extends Comparable | |
| public int | compareTo(Tuple2<T1, T2>
the object to be compared. that)Implements java. Compares this object with the specified object for order. |
| public < the type of the 3rd value in the tuple T3> Tuple3 | |
| public < the type of the 3rd value in the tuple T3, the type of the 4th value in the tuple T4> Tuple4 | |
| public < the type of the 3rd value in the tuple T3, the type of the 4th value in the tuple T4, the type of the 5th value in the tuple T5> Tuple5 | |
| public < the type of the 3rd value in the tuple T3, the type of the 4th value in the tuple T4, the type of the 5th value in the tuple T5, the type of the 6th value in the tuple T6> Tuple6 | |
| public < the type of the 3rd value in the tuple T3, the type of the 4th value in the tuple T4, the type of the 5th value in the tuple T5, the type of the 6th value in the tuple T6, the type of the 7th value in the tuple T7> Tuple7 | |
| public < the type of the 3rd value in the tuple T3, the type of the 4th value in the tuple T4, the type of the 5th value in the tuple T5, the type of the 6th value in the tuple T6, the type of the 7th value in the tuple T7, the type of the 8th value in the tuple T8> Tuple8 | |
| public boolean | equals(Object
the reference object with which to compare. o)Overrides java. Indicates whether some other object is "equal to" this one. |
| public int | |
| public < new type of the 1st component U1, new type of the 2nd component U2> Tuple2 | Returns: A new Tuple of same arity.the mapper function mapper)Maps the components of this tuple using a mapper function. |
| public < new type of the 1st component U1, new type of the 2nd component U2> Tuple2 | |
| public < new type of the 1st component U> Tuple2 | |
| public < new type of the 2nd component U> Tuple2 | |
| public Tuple2 | Returns: A new Tuple where the first element is the second element of this Tuple and the second element is the first element of this Tuple.Swaps the elements of this |
| public Map. | Returns: A java.util.Map.Entry where the first element is the key and the second element is the value.Converts the tuple to java.util.Map.Entry |
| public Seq | |
| public String | |
| public Tuple2 | Returns: a copy of this tuple with a new value for the 1st element of this Tuple.the new value value)Sets the 1st element of this tuple to the given |
| public Tuple2 | Returns: a copy of this tuple with a new value for the 2nd element of this Tuple.the new value value)Sets the 2nd element of this tuple to the given |
| _1 | back to summary |
|---|---|
| public final T1 _1 The 1st element of this tuple.
| |
| _2 | back to summary |
|---|---|
| public final T2 _2 The 2nd element of this tuple.
| |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID | |
| Tuple2 | back to summary |
|---|---|
| public Tuple2(T1 t1, T2 t2) Constructs a tuple of two elements.
| |
| _1 | back to summary |
|---|---|
| public T1 _1() Getter of the 1st element of this tuple.
| |
| _2 | back to summary |
|---|---|
| public T2 _2() Getter of the 2nd element of this tuple.
| |
| append | back to summary |
|---|---|
| public <T3> Tuple3 Append a value to this tuple.
| |
| apply | back to summary |
|---|---|
| public <U> U apply(BiFunction<? super T1, ? super T2, ? extends U> f) Transforms this tuple to an object of type U.
| |
| arity | back to summary |
|---|---|
| public int arity() Implements io. Doc from io. Returns the number of elements of this tuple.
| |
| comparator | back to summary |
|---|---|
| public static <T1, T2> Comparator | |
| compareTo | back to summary |
|---|---|
private static <U1 extends Comparable
| |
| compareTo | back to summary |
|---|---|
| public int compareTo(Tuple2<T1, T2> that) Implements java. Doc from java. Compares this object with the specified object for order. Returns a negative integer, zero, or a positive integer as this object is less than, equal to, or greater than the specified object. The implementor must ensure The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that | |
| concat | back to summary |
|---|---|
| public <T3> Tuple3 Concat a tuple's values to this tuple.
| |
| concat | back to summary |
|---|---|
| public <T3, T4> Tuple4 Concat a tuple's values to this tuple.
| |
| concat | back to summary |
|---|---|
| public <T3, T4, T5> Tuple5 Concat a tuple's values to this tuple.
| |
| concat | back to summary |
|---|---|
| public <T3, T4, T5, T6> Tuple6 Concat a tuple's values to this tuple.
| |
| concat | back to summary |
|---|---|
| public <T3, T4, T5, T6, T7> Tuple7 Concat a tuple's values to this tuple.
| |
| concat | back to summary |
|---|---|
| public <T3, T4, T5, T6, T7, T8> Tuple8 Concat a tuple's values to this tuple.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object o) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| map | back to summary |
|---|---|
| public <U1, U2> Tuple2 Maps the components of this tuple using a mapper function.
| |
| map | back to summary |
|---|---|
| public <U1, U2> Tuple2 Maps the components of this tuple using a mapper function for each component.
| |
| map1 | back to summary |
|---|---|
| public <U> Tuple2 Maps the 1st component of this tuple to a new value. | |
| map2 | back to summary |
|---|---|
| public <U> Tuple2 Maps the 2nd component of this tuple to a new value. | |
| swap | back to summary |
|---|---|
| public Tuple2 Swaps the elements of this
| |
| toEntry | back to summary |
|---|---|
| public Map. Converts the tuple to java.util.Map.Entry | |
| toSeq | back to summary |
|---|---|
| public Seq Implements io. Doc from io. Converts this tuple to a sequence. | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
| update1 | back to summary |
|---|---|
| public Tuple2 Sets the 1st element of this tuple to the given
| |
| update2 | back to summary |
|---|---|
| public Tuple2 Sets the 2nd element of this tuple to the given
| |