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