Interface TriConsumer<T,​U,​V>

  • Type Parameters:
    T - the type of the first object parameter
    U - the type of the second object parameter
    V - the type of the third object parameter
    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 TriConsumer<T,​U,​V>
    A consumer that takes three arguments.
    • Method Detail

      • accept

        void accept​(T t,
                    U u,
                    V v)
        Applies this consumer to the given arguments.
        Parameters:
        t - the first consumer argument
        u - the second consumer argument
        v - the third consumer argument
      • andThen

        default TriConsumer<T,​U,​V> andThen​(TriConsumer<? super T,​? super U,​? super V> after)
        Returns a new consumer that composes this consumer and the specified consumer.

        This returns a composed consumer that first calls this consumer and then calls the specified consumer.

        Parameters:
        after - the consumer to combine with
        Returns:
        the combined consumer, "this AND_THEN that"