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 int
applyAsInt
(int operand) Applies this operator to the given operand.int
applyAsIntUnsafe
(int operand) Applies this operator to the given operand.static ThrowableIntUnaryOperator
identity()
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:
applyAsInt
in 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
-