This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-lang.git
The following commit(s) were added to refs/heads/master by this push:
new 08f374f Javadoc.
08f374f is described below
commit 08f374f0d7185142e8065cfa0cca9e04fab74c4b
Author: Gary Gregory <[email protected]>
AuthorDate: Thu Mar 10 12:40:37 2022 -0500
Javadoc.
More formal constant definition.
---
.../org/apache/commons/lang3/function/FailableConsumer.java | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
diff --git
a/src/main/java/org/apache/commons/lang3/function/FailableConsumer.java
b/src/main/java/org/apache/commons/lang3/function/FailableConsumer.java
index aa7a8de..1d1d534 100644
--- a/src/main/java/org/apache/commons/lang3/function/FailableConsumer.java
+++ b/src/main/java/org/apache/commons/lang3/function/FailableConsumer.java
@@ -19,12 +19,17 @@ package org.apache.commons.lang3.function;
import java.util.Objects;
import java.util.function.Consumer;
+import java.util.function.Function;
/**
* A functional interface like {@link Consumer} that declares a {@code
Throwable}.
*
- * @param <T> Consumed type 1.
- * @param <E> Thrown exception.
+ * <p>
+ * This is a functional interface whose functional method is {@link
#accept(Object)}.
+ * </p>
+ *
+ * @param <T> the type of the input to the operation
+ * @param <E> Thrown exception type.
* @since 3.11
*/
@FunctionalInterface
@@ -32,7 +37,7 @@ public interface FailableConsumer<T, E extends Throwable> {
/** NOP singleton */
@SuppressWarnings("rawtypes")
- FailableConsumer NOP = t -> {/* NOP */};
+ FailableConsumer NOP = Function.identity()::apply;
/**
* Returns The NOP singleton.