public interface Triplet<T,U,V>
| Modifier and Type | Interface and Description |
|---|---|
static interface |
Triplet.Consumer<T,U,V>
Consumer that accept three values.
|
static interface |
Triplet.Function<T,U,V,R>
Function that apply three values.
|
| Modifier and Type | Method and Description |
|---|---|
default void |
accept(Triplet.Consumer<? super T,? super U,? super V> consumer)
Accept values with consumer.
|
<R> R |
apply(Triplet.Function<? super T,? super U,? super V,? extends R> func)
Apply triple using function.
|
static <T,U,V> Triplet<T,U,V> |
of(T first,
U second,
V third)
New triple.
|
default Pair<T,U> |
pop()
Skip third item to make a pair.
|
static <T,U,V> Iterable<Triplet<T,U,V>> |
zip(Iterable<? extends T> first,
Iterable<? extends U> second,
Iterable<? extends V> third)
Zip three iterables into single iterable of triplets.
|
<R> R apply(Triplet.Function<? super T,? super U,? super V,? extends R> func)
R - Result typefunc - Function to applydefault void accept(Triplet.Consumer<? super T,? super U,? super V> consumer)
consumer - Acceptordefault Pair<T,U> pop()
static <T,U,V> Triplet<T,U,V> of(T first, U second, V third)
T - First item typeU - Second item typeV - Third item typefirst - First item valuesecond - Second item valuethird - Third item valuestatic <T,U,V> Iterable<Triplet<T,U,V>> zip(Iterable<? extends T> first, Iterable<? extends U> second, Iterable<? extends V> third)
T - First iterable typeU - Second iterable typeV - Third iterable typefirst - Iterablesecond - Iterablethird - IterableCopyright © 2021. All rights reserved.