public static class LazyEither5.CompletableEither5<ORG,LT1,LT2,LT3,RT> extends java.lang.Object implements LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT>, Completable<ORG>
LazyEither5.CompletableEither5<ORG,LT1,LT2,LT3,RT>, LazyEither5.Lazy<ST,M,M2,M3,PT>, LazyEither5.Left1<ST,M,M2,M3,PT>, LazyEither5.Left2<ST,M,M2,M3,PT>, LazyEither5.Left3<ST,M,M2,M3,PT>, LazyEither5.Left4<ST,M,M2,M3,PT>, LazyEither5.Right<ST,M,M2,M3,PT>
Modifier and Type | Field and Description |
---|---|
java.util.concurrent.CompletableFuture<ORG> |
complete |
LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT> |
either |
Constructor and Description |
---|
CompletableEither5() |
Modifier and Type | Method and Description |
---|---|
<R1,R2> LazyEither5<java.lang.Throwable,LT1,LT2,R1,R2> |
bimap(java.util.function.Function<? super LT3,? extends R1> fn1,
java.util.function.Function<? super RT,? extends R2> fn2)
Transform this BiTransformable, changing two value types at once.
|
boolean |
complete(ORG done) |
boolean |
completeExceptionally(java.lang.Throwable error) |
Maybe<RT> |
filter(java.util.function.Predicate<? super RT> test)
Filter this Either4 resulting in a Maybe#none if it is not a Right instance or if the predicate does not
hold.
|
<RT1> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT1> |
flatMap(java.util.function.Function<? super RT,? extends LazyEither5<java.lang.Throwable,LT1,LT2,LT3,? extends RT1>> mapper)
Flattening transformation on this Either4.
|
<R> R |
fold(java.util.function.Function<? super RT,? extends R> present,
java.util.function.Supplier<? extends R> absent) |
<R> R |
fold(java.util.function.Function<? super java.lang.Throwable,? extends R> left1,
java.util.function.Function<? super LT1,? extends R> left2,
java.util.function.Function<? super LT2,? extends R> left3,
java.util.function.Function<? super LT3,? extends R> left4,
java.util.function.Function<? super RT,? extends R> right) |
Option<RT> |
get() |
boolean |
isDone() |
boolean |
isFailed() |
boolean |
isLeft1() |
boolean |
isLeft2() |
boolean |
isLeft3() |
boolean |
isLeft4() |
boolean |
isRight() |
<R> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,R> |
map(java.util.function.Function<? super RT,? extends R> fn)
Transform this functor using the supplied transformation function
|
void |
subscribe(org.reactivestreams.Subscriber<? super RT> sub) |
LazyEither5<RT,LT1,LT2,LT3,java.lang.Throwable> |
swap1() |
LazyEither5<java.lang.Throwable,RT,LT2,LT3,LT1> |
swap2() |
LazyEither5<java.lang.Throwable,LT1,RT,LT3,LT2> |
swap3() |
LazyEither5<java.lang.Throwable,LT1,LT2,RT,LT3> |
swap4() |
<T> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,T> |
unit(T unit) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
accumulate, always, applyAny, bipeek, coflatMap, consumeAny, either4, either5, filter, filterNot, foEval, foldAny, forEach2, forEach3, forEach4, fromFuture, fromIterable, fromLazy, fromPublisher, later, left1, left1Eval, left2, left2Eval, left3, left3Eval, left4, left4Eval, nest, notNull, ofType, peek, right, rightEval, sequence, sequence, toEither, toIor, toTrampoline, traverse, traverse, visitAny, visitAny, zip
orElseUse, orElseUse
asSupplier, collect, fold, forEach, generate, isPresent, iterate, iterator, mkString, nonEmptyList, nonEmptyListGet, orElse, orElseGet, print, print, printErr, printOut, stream, toEither, toLazyEither, toLeft, toMaybe, toOption, toOptional, toRight, toTry, toTry, toTry
public final java.util.concurrent.CompletableFuture<ORG> complete
public final LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT> either
public boolean isFailed()
isFailed
in interface Completable<ORG>
public boolean isDone()
isDone
in interface Completable<ORG>
public boolean complete(ORG done)
complete
in interface Completable<ORG>
public boolean completeExceptionally(java.lang.Throwable error)
completeExceptionally
in interface Completable<ORG>
public <R> R fold(java.util.function.Function<? super java.lang.Throwable,? extends R> left1, java.util.function.Function<? super LT1,? extends R> left2, java.util.function.Function<? super LT2,? extends R> left3, java.util.function.Function<? super LT3,? extends R> left4, java.util.function.Function<? super RT,? extends R> right)
public Maybe<RT> filter(java.util.function.Predicate<? super RT> test)
LazyEither5
filter
in interface Filters<RT>
filter
in interface LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT>
test
- Predicate to applyHKT to filter this Either4public <RT1> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT1> flatMap(java.util.function.Function<? super RT,? extends LazyEither5<java.lang.Throwable,LT1,LT2,LT3,? extends RT1>> mapper)
LazyEither5
public LazyEither5<java.lang.Throwable,LT1,LT2,RT,LT3> swap4()
public LazyEither5<java.lang.Throwable,LT1,RT,LT3,LT2> swap3()
public LazyEither5<java.lang.Throwable,RT,LT2,LT3,LT1> swap2()
public LazyEither5<RT,LT1,LT2,LT3,java.lang.Throwable> swap1()
public boolean isRight()
public boolean isLeft1()
public boolean isLeft2()
public boolean isLeft3()
public boolean isLeft4()
public <R1,R2> LazyEither5<java.lang.Throwable,LT1,LT2,R1,R2> bimap(java.util.function.Function<? super LT3,? extends R1> fn1, java.util.function.Function<? super RT,? extends R2> fn2)
BiTransformable
MapX<String,Integer> map = MapXs.of("hello",2);
MapX<String,Integer> transformedMap = map.bimap(s->s+" world",i->i*4);
//["hello world",8]
bimap
in interface BiTransformable<LT3,RT>
bimap
in interface LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT>
fn1
- transformation function for the first typefn2
- transformation function for the second typepublic <R> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,R> map(java.util.function.Function<? super RT,? extends R> fn)
Transformable
of(1,2,3).map(i->i*2)
//[2,4,6]
map
in interface Transformable<RT>
map
in interface LazyEither5<java.lang.Throwable,LT1,LT2,LT3,RT>
fn
- Transformation functionpublic <T> LazyEither5<java.lang.Throwable,LT1,LT2,LT3,T> unit(T unit)
public <R> R fold(java.util.function.Function<? super RT,? extends R> present, java.util.function.Supplier<? extends R> absent)