public static class IntSupplier.Util
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static IntSupplier |
safe(ThrowableIntSupplier<java.lang.Throwable> throwableSupplier)
Creates a safe
IntSupplier. |
static IntSupplier |
safe(ThrowableIntSupplier<java.lang.Throwable> throwableSupplier,
int resultIfFailed)
Creates a safe
IntSupplier. |
public static IntSupplier safe(@NotNull ThrowableIntSupplier<java.lang.Throwable> throwableSupplier)
IntSupplier.throwableSupplier - the supplier that may throw an exceptionIntSupplierjava.lang.NullPointerException - if throwableSupplier is nullsafe(com.annimon.stream.function.ThrowableIntSupplier, int)public static IntSupplier safe(@NotNull ThrowableIntSupplier<java.lang.Throwable> throwableSupplier, int resultIfFailed)
IntSupplier.throwableSupplier - the supplier that may throw an exceptionresultIfFailed - the result which returned if exception was thrownIntSupplierjava.lang.NullPointerException - if throwableSupplier is null