T
- The type of the argument to the function.R
- The type of the result of the supplier.E
- The type of Exceptions thrown by this function.@Public @FunctionalInterface public interface FunctionWithException<T,R,E extends Throwable>
Function
that may throw exceptions.Modifier and Type | Method and Description |
---|---|
R |
apply(T value)
Calls this function.
|
static <A,B> Function<A,B> |
unchecked(FunctionWithException<A,B,?> functionWithException)
Convert at
FunctionWithException into a Function . |
static <A,B> Function<A,B> unchecked(FunctionWithException<A,B,?> functionWithException)
FunctionWithException
into a Function
.A
- input typeB
- output typefunctionWithException
- function with exception to convert into a functionFunction
which throws all checked exception as an unchecked exception.Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.