R - the type of the result of the functionE - the type of the thrown checked exception@FunctionalInterface public interface ThrowingIntFunction<R,E extends Exception>
IntFunction for primitive ints from the java.util.function package.
This allows wrapping a exceptions in a runtime exception: WrappedException
As this adheres to the IntFunction interface, compose and andThen (as you might be familiar with from
Function are not available.
| Modifier and Type | Method and Description |
|---|---|
R |
apply(int i) |
default IntFunction<Optional<R>> |
lift() |
static <R> IntFunction<Optional<R>> |
lifted(ThrowingIntFunction<R,?> f) |
static <R> IntFunction<R> |
sneaky(ThrowingIntFunction<? extends R,?> function) |
default IntFunction<R> |
uncheck() |
static <R> IntFunction<R> |
unchecked(ThrowingIntFunction<R,?> f) |
default IntFunction<R> uncheck()
static <R> IntFunction<R> unchecked(ThrowingIntFunction<R,?> f)
static <R> IntFunction<Optional<R>> lifted(ThrowingIntFunction<R,?> f)
static <R> IntFunction<R> sneaky(ThrowingIntFunction<? extends R,?> function)
default IntFunction<Optional<R>> lift()
Copyright © 2020. All rights reserved.