@Mutable @Functional public interface Consumer<INPUT> extends FailableConsumer<INPUT,RuntimeException>
INPUT without returning a result.| Modifier and Type | Field and Description |
|---|---|
static @Nonnull Consumer<Object> |
DO_NOTHING
Stores a consumer that does nothing.
|
| Modifier and Type | Method and Description |
|---|---|
default @Nonnull Consumer<INPUT> |
after(@Nonnull Consumer<? super INPUT> consumer)
Returns the composition of the given consumer followed by this consumer.
|
default <INITIAL_INPUT> |
after(@Nonnull UnaryFunction<? super INITIAL_INPUT,? extends INPUT> function)
Returns the composition of the given function followed by this consumer.
|
default @Nonnull UnaryFunction<INPUT,Void> |
asFunction()
Returns this consumer as a unary function that always returns null.
|
default @Nonnull Consumer<INPUT> |
before(@Nonnull Consumer<? super INPUT> consumer)
Returns the composition of this consumer followed by the given consumer.
|
default @Nonnull Consumer<INPUT> |
synchronize()
Returns a consumer that synchronizes on this consumer.
|
after, after, before, compose, consume, suppressExceptions, suppressExceptions@Pure @Capturable @Nonnull default @Nonnull Consumer<INPUT> before(@Captured @Nonnull @Nonnull Consumer<? super INPUT> consumer)
@Pure @Capturable @Nonnull default @Nonnull Consumer<INPUT> after(@Captured @Nonnull @Nonnull Consumer<? super INPUT> consumer)
@Pure @Capturable @Nonnull default <INITIAL_INPUT> @Nonnull Consumer<INITIAL_INPUT> after(@Nonnull @Nonnull UnaryFunction<? super INITIAL_INPUT,? extends INPUT> function)
@Pure @Nonnull default @Nonnull UnaryFunction<INPUT,Void> asFunction()
FailableConsumerasFunction in interface FailableConsumer<INPUT,RuntimeException>@Pure @Nonnull default @Nonnull Consumer<INPUT> synchronize()
FailableConsumersynchronize in interface FailableConsumer<INPUT,RuntimeException>Copyright © 2017. All rights reserved.