Package org.apache.commons.io.function
Interface IOUnaryOperator<T>
-
- Type Parameters:
T
- the type of the operand and result of the operator.
- All Superinterfaces:
IOFunction<T,T>
- 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 IOUnaryOperator<T> extends IOFunction<T,T>
LikeUnaryOperator
but throwsIOException
.- Since:
- 2.12.0
- See Also:
UnaryOperator
,IOFunction
-
-
Method Summary
All Methods Static Methods Instance Methods Default Methods Modifier and Type Method Description default java.util.function.UnaryOperator<T>
asUnaryOperator()
Creates aUnaryOperator
for this instance that throwsUncheckedIOException
instead ofIOException
.static <T> IOUnaryOperator<T>
identity()
Creates a unary operator that always returns its input argument.
-
-
-
Method Detail
-
identity
static <T> IOUnaryOperator<T> identity()
Creates a unary operator that always returns its input argument.- Type Parameters:
T
- the type of the input and output of the operator.- Returns:
- a unary operator that always returns its input argument.
-
asUnaryOperator
default java.util.function.UnaryOperator<T> asUnaryOperator()
Creates aUnaryOperator
for this instance that throwsUncheckedIOException
instead ofIOException
.- Returns:
- an unchecked BiFunction.
-
-