Uses of Interface
io.vavr.Function2
Packages that use Function2
Package
Description
Beside
API
the io.vavr package contains core types like (Checked)Functions and Tuples.-
Uses of Function2 in io.vavr
Modifier and TypeMethodDescriptionReturns a composed function that first applies this Function2 to the given argument and then applies Functionafter
to the result.Applies this function partially to one argument.Applies this function partially to two arguments.Applies this function partially to three arguments.Applies this function partially to 4 arguments.Applies this function partially to 5 arguments.Applies this function partially to 6 arguments.static <T1,
T2, R>
Function2<T1, T2, R> Function2.constant
(R value) Returns a function that always returns the constant value that you give in parameter.static <T1,
T2, R>
Function2<T1, T2, R> Alias forof(Function2)
CheckedFunction2.lift
(CheckedFunction2<? super T1, ? super T2, ? extends R> partialFunction) Lifts the givenpartialFunction
into a total function that returns anOption
result.Function2.lift
(BiFunction<? super T1, ? super T2, ? extends R> partialFunction) Lifts the givenpartialFunction
into a total function that returns anOption
result.CheckedFunction2.liftTry
(CheckedFunction2<? super T1, ? super T2, ? extends R> partialFunction) Lifts the givenpartialFunction
into a total function that returns anTry
result.Function2.liftTry
(BiFunction<? super T1, ? super T2, ? extends R> partialFunction) Lifts the givenpartialFunction
into a total function that returns anTry
result.Function2.memoized()
Returns a memoizing version of this function, which computes the return value for given arguments only one time.static <T1,
T2, R>
Function2<T1, T2, R> Narrows the givenFunction2<? super T1, ? super T2, ? extends R>
toFunction2<T1, T2, R>
static <T1,
T2, R>
Function2<T1, T2, R> CheckedFunction2.recover
(Function<? super Throwable, ? extends BiFunction<? super T1, ? super T2, ? extends R>> recover) Return a composed function that first applies this CheckedFunction2 to the given arguments and in case of throwable try to get value fromrecover
function with same arguments and throwable information.Function2.reversed()
Returns a reversed version of this function.static <T1,
T2, R>
Function2<T1, T2, R> API.unchecked
(CheckedFunction2<T1, T2, R> f) Alias forCheckedFunction2.unchecked()
CheckedFunction2.unchecked()
Returns an unchecked function that will sneaky throw if an exceptions occurs when applying the function.Modifier and TypeMethodDescriptionstatic <T1,
T2, R>
Function2<T1, T2, R> Alias forof(Function2)
static <T1,
T2, R>
Function2<T1, T2, R> Narrows the givenFunction2<? super T1, ? super T2, ? extends R>
toFunction2<T1, T2, R>
static <T1,
T2, R>
Function2<T1, T2, R> -
Uses of Function2 in io.vavr.control
Methods in io.vavr.control with parameters of type Function2