接口的使用
cn.taketoday.util.function.ThrowingConsumer
使用ThrowingConsumer的程序包
-
cn.taketoday.util.function中ThrowingConsumer的使用
修饰符和类型方法说明static <T> ThrowingConsumer<T>ThrowingConsumer.of(ThrowingConsumer<T> consumer) Lambda friendly convenience method that can be used to create aThrowingConsumerwhere theaccept(Object)method wraps any checked exception thrown by the supplied lambda expression or method reference.static <T> ThrowingConsumer<T>ThrowingConsumer.of(ThrowingConsumer<T> consumer, BiFunction<String, Exception, RuntimeException> exceptionWrapper) Lambda friendly convenience method that can be used to create aThrowingConsumerwhere theaccept(Object)method wraps any thrown checked exceptions using the givenexceptionWrapper.default ThrowingConsumer<T>ThrowingConsumer.throwing(BiFunction<String, Exception, RuntimeException> exceptionWrapper) Return a newThrowingConsumerwhere theaccept(Object)method wraps any thrown checked exceptions using the givenexceptionWrapper.修饰符和类型方法说明static <T> ThrowingConsumer<T>ThrowingConsumer.of(ThrowingConsumer<T> consumer) Lambda friendly convenience method that can be used to create aThrowingConsumerwhere theaccept(Object)method wraps any checked exception thrown by the supplied lambda expression or method reference.static <T> ThrowingConsumer<T>ThrowingConsumer.of(ThrowingConsumer<T> consumer, BiFunction<String, Exception, RuntimeException> exceptionWrapper) Lambda friendly convenience method that can be used to create aThrowingConsumerwhere theaccept(Object)method wraps any thrown checked exceptions using the givenexceptionWrapper.