Package com.globalmentor.io.function
Interface IOIntUnaryOperator
-
- 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 IOIntUnaryOperator
Represents an operation on a singleint
-valued operand that produces anint
-valued result. This is the primitive type specialization ofIOUnaryOperator
forint
.This interface is similar to
IntUnaryOperator
except that it is allowed to throw anIOException
.- Author:
- Magno N A Cruz
- See Also:
IOUnaryOperator
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default IOIntUnaryOperator
andThen(IOIntUnaryOperator after)
This method is the same asIntUnaryOperator.andThen(IntUnaryOperator)
, but with a support forIOException
.int
applyAsInt(int operand)
This method is the same asIntUnaryOperator.applyAsInt(int)
, but with a support forIOException
.default IOIntUnaryOperator
compose(IOIntUnaryOperator before)
This method is the same asIntUnaryOperator.compose(IntUnaryOperator)
, but with a support forIOException
.static IOIntUnaryOperator
identity()
This method is the same asIntUnaryOperator.identity()
, but with a support forIOException
.
-
-
-
Method Detail
-
applyAsInt
int applyAsInt(int operand) throws java.io.IOException
This method is the same as
IntUnaryOperator.applyAsInt(int)
, but with a support forIOException
.- Parameters:
operand
- The operand.- Returns:
- The operator result.
- Throws:
java.io.IOException
- if there is an I/O error performing the operation.
-
compose
default IOIntUnaryOperator compose(@Nonnull IOIntUnaryOperator before) throws java.io.IOException
This method is the same as
IntUnaryOperator.compose(IntUnaryOperator)
, but with a support forIOException
.- Parameters:
before
- The operator to apply before this operator is applied.- Returns:
- A composed operator that first applies the
before
operator and then applies this operator. - Throws:
java.io.IOException
- if there is an I/O error performing the operation.- See Also:
andThen(IOIntUnaryOperator)
-
andThen
default IOIntUnaryOperator andThen(@Nonnull IOIntUnaryOperator after) throws java.io.IOException
This method is the same as
IntUnaryOperator.andThen(IntUnaryOperator)
, but with a support forIOException
.- Parameters:
after
- The operator to apply after this operator is applied.- Returns:
- A composed operator that first applies this operator and then applies the
after
operator. - Throws:
java.io.IOException
- if there is an I/O error performing the operation.- See Also:
compose(IOIntUnaryOperator)
-
identity
static IOIntUnaryOperator identity() throws java.io.IOException
This method is the same as
IntUnaryOperator.identity()
, but with a support forIOException
.- Returns:
- A unary operator that always returns its input argument.
- Throws:
java.io.IOException
- if there is an I/O error performing the operation.
-
-