Package com.globalmentor.io.function
Interface IOIntConsumer
- 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 that accepts a single
int
-valued argument and returns no result. This is the primitive type specialization of
Consumer
for int
. Unlike most other functional interfaces, IntConsumer
is expected to operate via side-effects.
This interface is similar to IntConsumer
except that it is allowed to throw an IOException
.
- Author:
- Magno N A Cruz
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoid
accept
(int value) This method is the same asIntConsumer.accept(int)
, but with a support forIOException
.default IOIntConsumer
andThen
(IOIntConsumer after) This method is the same asIntConsumer.andThen(IntConsumer)
, but with a support forIOException
.
-
Method Details
-
accept
This method is the same as
IntConsumer.accept(int)
, but with a support forIOException
.- Parameters:
value
- The input argument.- Throws:
IOException
- if there is an I/O error performing the operation.
-
andThen
This method is the same as
IntConsumer.andThen(IntConsumer)
, but with a support forIOException
.- Parameters:
after
- The operation to perform after this operation.- Returns:
- A composed
IntConsumer
that performs this operation followed by theafter
operation in sequence. - Throws:
IOException
- if there is an I/O error performing the operation.
-