Interface ThrowingFunction<T,R,X extends Throwable>
- Type Parameters:
T- the type of the input to the functionR- the type of the result of the functionX- the type of the exception thrown by the function
- All Superinterfaces:
Function<T,R>
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
public interface ThrowingFunction<T,R,X extends Throwable>
extends Function<T,R>
An extension of
Function allowing throwing calls in its body.-
Method Summary
-
Method Details
-
applyChecked
Applies this function to the given argument.- Parameters:
t- the function argument- Returns:
- the function result
- Throws:
X- if an exception happens
-
invoke
Deprecated.in favor ofapplyChecked(Object)Applies this function to the given argument.- Parameters:
t- the function argument- Returns:
- the function result
- Throws:
X- if an exception happens
-
apply
-
applyChecked(Object)