E - The extension@FunctionalInterface public interface IntConsumerWithThrowable<E extends Throwable> extends IntConsumer
| Modifier and Type | Method and Description |
|---|---|
default void |
accept(int v1)
Overridden method of IntConsumerWithThrowable that will call acceptWithThrowable, but catching any exceptions.
|
void |
acceptWithThrowable(int v1)
Functional method that will throw exceptions.
|
static <E extends Throwable> |
aIntConsumerThatUnsafelyThrowsUnchecked(IntConsumerWithThrowable<E> intconsumerwiththrowable)
Utility method to unwrap lambdas of type IntConsumer and withUncheckedThrowable any Exception
|
static <E extends Throwable> |
asIntConsumerWithThrowable(IntConsumer intconsumer)
Utility method to convert IntConsumerWithThrowable
|
static <E extends Throwable> |
castIntConsumerWithThrowable(IntConsumerWithThrowable<E> intconsumerwiththrowable)
Utility method to mark lambdas of type IntConsumerWithThrowable
|
default IntConsumerWithThrowable<E> |
onException(BiConsumer<Throwable,Object[]> consumer) |
default IntConsumerWithThrowable<E> |
onException(Consumer<Throwable> consumer) |
default IntConsumer |
thatThrowsNothing() |
default IntConsumer |
thatUnsafelyThrowsUnchecked() |
default IntConsumerWithThrowable<E> |
withLogging()
Will log WARNING level exceptions on logger if they occur within the interface
|
default IntConsumerWithThrowable<E> |
withLogging(org.slf4j.Logger logger)
Will log WARNING level exceptions on logger if they occur within the interface
|
default IntConsumerWithThrowable<E> |
withLogging(org.slf4j.Logger logger,
String message) |
andThenstatic <E extends Throwable> IntConsumerWithThrowable<E> castIntConsumerWithThrowable(IntConsumerWithThrowable<E> intconsumerwiththrowable)
E - The type this interface is allowed to throwintconsumerwiththrowable - The interface instancestatic <E extends Throwable> IntConsumer aIntConsumerThatUnsafelyThrowsUnchecked(IntConsumerWithThrowable<E> intconsumerwiththrowable) throws E extends Throwable
E - The type this interface is allowed to throwintconsumerwiththrowable - The interface instanceE - the original Exception from intconsumerwiththrowableE extends Throwablestatic <E extends Throwable> IntConsumerWithThrowable<E> asIntConsumerWithThrowable(IntConsumer intconsumer)
E - The type this interface is allowed to throwintconsumer - The interface instancedefault void accept(int v1)
accept in interface IntConsumerv1 - parameter to overridden methodvoid acceptWithThrowable(int v1)
throws E extends Throwable
default IntConsumer thatThrowsNothing()
default IntConsumer thatUnsafelyThrowsUnchecked() throws E extends Throwable
default IntConsumerWithThrowable<E> withLogging(org.slf4j.Logger logger, String message)
logger - The logger to log exceptions onmessage - A message to use for logging exceptionsdefault IntConsumerWithThrowable<E> withLogging(org.slf4j.Logger logger)
logger - The logger instance to log exceptions ondefault IntConsumerWithThrowable<E> withLogging()
default IntConsumerWithThrowable<E> onException(Consumer<Throwable> consumer)
consumer - An exception consumer.default IntConsumerWithThrowable<E> onException(BiConsumer<Throwable,Object[]> consumer)
consumer - An exception consumer.Copyright © 2017. All rights reserved.