Package io.vavr
Class API.ForLazy3Future<T1,T2,T3>
- java.lang.Object
-
- io.vavr.API.ForLazy3Future<T1,T2,T3>
-
- Type Parameters:
T1- the component type of the 1st FutureT2- the component type of the 2nd FutureT3- the component type of the 3rd Future
- Enclosing class:
- API
public static class API.ForLazy3Future<T1,T2,T3> extends java.lang.ObjectA lazily evaluatedFor-comprehension with three Futures.Constructed via
For(...)and evaluated by callingyield(...). Construction is side-effect free; underlying Futures are traversed only whenyield(...)is invoked.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <R> Future<R>yield(@NonNull Function3<? super T1,? super T2,? super T3,? extends R> f)Produces results by mapping the Cartesian product of all bound values.
-
-
-
Method Detail
-
yield
public <R> Future<R> yield(@NonNull Function3<? super T1,? super T2,? super T3,? extends R> f)
Produces results by mapping the Cartesian product of all bound values.Evaluation is lazy and delegated to the underlying Futures by composing
flatMapandmapchains.- Type Parameters:
R- the element type of the resultingFuture- Parameters:
f- a function mapping a tuple of bound values to a result- Returns:
- an
Futurecontaining mapped results - Throws:
java.lang.NullPointerException- iffisnull
-
-