Module jp.cafebabe.birthmarks
Package jp.cafebabe.birthmarks.entities
Class Couple<L extends Serializable,R extends Serializable>
- java.lang.Object
-
- jp.cafebabe.birthmarks.entities.Couple<L,R>
-
- All Implemented Interfaces:
Serializable
public class Couple<L extends Serializable,R extends Serializable> extends Object implements Serializable
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
apply(BiConsumer<L,R> action)
boolean
equals(Object other)
boolean
filter(BiPredicate<L,R> predicate)
int
hashCode()
L
left()
<F> F
map(BiFunction<L,R,F> mapper)
<L2 extends Serializable,R2 extends Serializable>
Couple<L2,R2>map(Function<L,L2> leftMapper, Function<R,R2> rightMapper)
static <L extends Serializable,R extends Serializable>
Couple<L,R>of(L left, R right)
R
right()
Couple<R,L>
swap()
-
-
-
Method Detail
-
left
public L left()
-
right
public R right()
-
of
public static <L extends Serializable,R extends Serializable> Couple<L,R> of(L left, R right)
-
apply
public void apply(BiConsumer<L,R> action)
-
filter
public boolean filter(BiPredicate<L,R> predicate)
-
map
public <F> F map(BiFunction<L,R,F> mapper)
-
map
public <L2 extends Serializable,R2 extends Serializable> Couple<L2,R2> map(Function<L,L2> leftMapper, Function<R,R2> rightMapper)
-
-