java.util.function.ObjIntConsumer<T>@FunctionalInterface
public interface ThrowingObjIntConsumer<T>
extends java.util.function.ObjIntConsumer<T>
object-valued and an int-valued argument, and returns no result, possibly throwing an exception.| Modifier and Type | Method | Description |
|---|---|---|
default void |
accept(T former,
int latter) |
Performs this operation on the given arguments.
|
void |
acceptThrowing(T former,
int latter) |
Performs this operation on the given arguments.
|
default java.util.function.ObjIntConsumer<T> |
fallbackTo(java.util.function.ObjIntConsumer<T> fallback) |
Returns an
ObjIntConsumer performing the given operation on the arguments if this operation throws an exception. |
default java.util.function.ObjIntConsumer<T> |
fallbackTo(java.util.function.ObjIntConsumer<T> fallback,
java.util.function.Consumer<java.lang.Exception> exceptionConsumer) |
Returns an
ObjIntConsumer performing the given operation on the arguments if this operation throws an exception. |
default ThrowingObjIntConsumer<T> |
orThrow(java.lang.Class<? extends java.lang.RuntimeException> exceptionClass) |
Returns a
ThrowingObjIntConsumer throwing an exception of the given type if this operation throws an exception. |
default ThrowingObjIntConsumer<T> |
orThrow(java.lang.Class<? extends java.lang.RuntimeException> exceptionClass,
java.lang.String message) |
Returns a
ThrowingObjIntConsumer throwing an exception of the given type if this operation throws an exception. |
default ThrowingObjIntConsumer<T> |
orTryWith(ThrowingObjIntConsumer<? super T> other) |
Returns a
ThrowingObjIntConsumer performing the given operation on the arguments if this operation throws an exception. |
default ThrowingObjIntConsumer<T> |
orTryWith(ThrowingObjIntConsumer<? super T> other,
java.util.function.Consumer<java.lang.Exception> exceptionConsumer) |
Returns a
ThrowingObjIntConsumer performing the given operation on the arguments if this operation throws an exception. |
default void accept(T former, int latter)
UncheckedException.accept in interface java.util.function.ObjIntConsumer<T>void acceptThrowing(T former, int latter) throws java.lang.Exception
java.lang.Exceptiondefault java.util.function.ObjIntConsumer<T> fallbackTo(java.util.function.ObjIntConsumer<T> fallback)
ObjIntConsumer performing the given operation on the arguments if this operation throws an exception.java.lang.IllegalArgumentException - if fallback is nulldefault java.util.function.ObjIntConsumer<T> fallbackTo(java.util.function.ObjIntConsumer<T> fallback, java.util.function.Consumer<java.lang.Exception> exceptionConsumer)
ObjIntConsumer performing the given operation on the arguments if this operation throws an exception.java.lang.IllegalArgumentException - if fallback is nulldefault ThrowingObjIntConsumer<T> orThrow(java.lang.Class<? extends java.lang.RuntimeException> exceptionClass)
ThrowingObjIntConsumer throwing an exception of the given type if this operation throws an exception.
The original exception thrown by this operation is the cause of the thrown exception.
The exception class must have a constructor accepting a single Throwable as an argument.
java.lang.IllegalArgumentException - if exceptionClass is nulldefault ThrowingObjIntConsumer<T> orThrow(java.lang.Class<? extends java.lang.RuntimeException> exceptionClass, java.lang.String message)
ThrowingObjIntConsumer throwing an exception of the given type if this operation throws an exception.
The original exception thrown by this operation is the cause of the thrown exception.
The exception class must have a constructor accepting String and Throwable as arguments.
java.lang.IllegalArgumentException - if exceptionClass is nulldefault ThrowingObjIntConsumer<T> orTryWith(ThrowingObjIntConsumer<? super T> other)
ThrowingObjIntConsumer performing the given operation on the arguments if this operation throws an exception.java.lang.IllegalArgumentException - if other is nulldefault ThrowingObjIntConsumer<T> orTryWith(ThrowingObjIntConsumer<? super T> other, java.util.function.Consumer<java.lang.Exception> exceptionConsumer)
ThrowingObjIntConsumer performing the given operation on the arguments if this operation throws an exception.java.lang.IllegalArgumentException - if other is null