Interface ThrowableIntUnaryOperator
- All Superinterfaces:
IntUnaryOperator
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Represents an operation on a single
int-valued operand that produces an
int-valued result. This is the primitive type specialization of ThrowableUnaryOperator
for int.
Permits checked exceptions unlike IntUnaryOperator
This is a functional interface whose functional method is
applyAsInt(int).
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondefault intapplyAsInt(int operand) Applies this operator to the given operand.intapplyAsIntUnsafe(int operand) Applies this operator to the given operand.static ThrowableIntUnaryOperatoridentity()Returns a unary operator that always returns its input argument.Methods inherited from interface java.util.function.IntUnaryOperator
andThen, compose
-
Method Details
-
applyAsIntUnsafe
Applies this operator to the given operand.- Parameters:
operand- the operand- Returns:
- the operator result
- Throws:
Throwable- occurred during processing
-
applyAsInt
default int applyAsInt(int operand) Applies this operator to the given operand.- Specified by:
applyAsIntin interfaceIntUnaryOperator- Parameters:
operand- the operand- Returns:
- the operator result
-
identity
Returns a unary operator that always returns its input argument.- Returns:
- a unary operator that always returns its input argument
-