Interface ThrowableBiConsumer<T,U>

Type Parameters:
T - the type of the first argument to the operation
U - the type of the second argument to the operation
All Superinterfaces:
BiConsumer<T,U>
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 ThrowableBiConsumer<T,U> extends BiConsumer<T,U>
Represents an operation that accepts two input arguments and returns no result. This is the two-arity specialization of ThrowableConsumer. Unlike most other functional interfaces, BiConsumer is expected to operate via side-effects.

Permits checked exceptions unlike BiConsumer

This is a functional interface whose functional method is accept(Object, Object).

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    accept(T t, U u)
    Performs this operation on the given arguments.
    void
    acceptUnsafe(T t, U u)
    Performs this operation on the given arguments.

    Methods inherited from interface java.util.function.BiConsumer

    andThen
  • Method Details

    • acceptUnsafe

      void acceptUnsafe(T t, U u) throws Throwable
      Performs this operation on the given arguments.
      Parameters:
      t - the first input argument
      u - the second input argument
      Throws:
      Throwable - occurred during processing
    • accept

      default void accept(T t, U u)
      Performs this operation on the given arguments.
      Specified by:
      accept in interface BiConsumer<T,U>
      Parameters:
      t - the first input argument
      u - the second input argument