com.github.phantomthief.util.ThrowableBiConsumer Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of more-lambdas Show documentation
Show all versions of more-lambdas Show documentation
Some useful lambda implements for Java 8.
package com.github.phantomthief.util;
import static java.util.Objects.requireNonNull;
/**
* @author w.vela
*/
@FunctionalInterface
public interface ThrowableBiConsumer {
void accept(T t, U u) throws X;
default ThrowableBiConsumer
andThen(ThrowableBiConsumer super T, ? super U, X> after) {
requireNonNull(after);
return (t, u) -> {
accept(t, u);
after.accept(t, u);
};
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy