A
- the type of the first argument of the consumer@FunctionalInterface
public interface SafeConsumer<A>
Consumer
that can throw an exception.
This interface can be implemented with a lambda function.
Modifier and Type | Method and Description |
---|---|
void |
accept(A a)
Operates with one parameter and returns
void . |
static <T> java.util.function.Consumer<T> |
ignore(SafeConsumer<T> safeConsumer) |
static <T> java.util.function.Consumer<T> ignore(SafeConsumer<T> safeConsumer)
void accept(A a) throws java.lang.Exception
void
. This function can
be implemented explicitly or with a lambda.a
- the first function argumentjava.lang.Exception