Interface FailableSupplier<T,E extends java.lang.Throwable>
-
- Type Parameters:
T- Return type.E- The kind of thrown exception or error.
- All Known Subinterfaces:
ConcurrentInitializer<T>
- All Known Implementing Classes:
AbstractConcurrentInitializer,AbstractConcurrentInitializer.AbstractBuilder,AbstractSupplier,AtomicInitializer,AtomicInitializer.Builder,AtomicSafeInitializer,AtomicSafeInitializer.Builder,BackgroundInitializer,BackgroundInitializer.Builder,CallableBackgroundInitializer,ConstantInitializer,LazyInitializer,LazyInitializer.Builder,MultiBackgroundInitializer
- 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 FailableSupplier<T,E extends java.lang.Throwable>A functional interface likeSupplierthat declares aThrowable.- Since:
- 3.11
-
-
Field Summary
Fields Modifier and Type Field Description static FailableSupplierNULReturns the singleton supplier that always returns null.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description Tget()Supplies an objectstatic <T,E extends java.lang.Exception>
FailableSupplier<T,E>nul()Returns the singleton supplier that always returns null.
-
-
-
Field Detail
-
NUL
static final FailableSupplier NUL
Returns the singleton supplier that always returns null.This supplier never throws an exception.
- Since:
- 3.14.0
-
-
Method Detail
-
nul
static <T,E extends java.lang.Exception> FailableSupplier<T,E> nul()
Returns the singleton supplier that always returns null.This supplier never throws an exception.
- Type Parameters:
T- Supplied type.E- The kind of thrown exception or error.- Returns:
- The NUL singleton.
- Since:
- 3.14.0
-
-