@FunctionalInterface public interface LongConsumer
long
-consuming primitive type specialization of
Consumer
. Unlike most other functional interfaces, LongConsumer
is expected to operate via side-effects.Consumer
Modifier and Type | Method and Description |
---|---|
void |
accept(long value)
Accept an input value.
|
default LongConsumer |
chain(LongConsumer other)
Returns a
LongConsumer which performs, in sequence, the operation
represented by this object followed by the operation represented by
another LongConsumer . |
void accept(long value)
value
- the input valuedefault LongConsumer chain(LongConsumer other)
LongConsumer
which performs, in sequence, the operation
represented by this object followed by the operation represented by
another LongConsumer
.
Any exceptions thrown by either accept
method are relayed
to the caller; if performing this operation throws an exception, the
other operation will not be performed.
other
- a LongConsumer which will be chained after this
LongConsumeraccept
method
of this LongConsumer and the accept
method of the specified LongConsumer
operationNullPointerException
- if other is null Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2013, Oracle and/or its affiliates. All rights reserved.
DRAFT internal-0