接口的使用
cn.taketoday.util.function.ThrowingConsumer
使用ThrowingConsumer的程序包
程序包
说明
Support classes for components that contribute generated code equivalent to a
runtime behavior.
Useful generic
java.util.function helper classes.-
cn.taketoday.aot.generate中ThrowingConsumer的使用
修饰符和类型方法说明default voidGeneratedFiles.addFile(GeneratedFiles.Kind kind, String path, ThrowingConsumer<Appendable> content) Add a generated file of the specifiedGeneratedFiles.Kindwith content written to anAppendablepassed to the givenThrowingConsumer.default voidGeneratedFiles.addResourceFile(String path, ThrowingConsumer<Appendable> content) Add a generatedresource filewith content written to anAppendablepassed to the givenThrowingConsumer.default voidGeneratedFiles.addSourceFile(String className, ThrowingConsumer<Appendable> content) Add a generatedsource filewith content written to anAppendablepassed to the givenThrowingConsumer.参数类型为ThrowingConsumer的cn.taketoday.aot.generate中的构造器 -
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.