@FunctionalInterface
public interface ByteConsumer
extends java.util.function.Consumer<java.lang.Byte>, java.util.function.IntConsumer
Consumer
; provides methods to consume a primitive type both as object
and as primitive.
Except for the boolean case, this interface extends both a parameterized Consumer
and a type-specific JDK consumer (e.g., IntConsumer
). For types missing
a type-specific JDK consumer (e.g., short
or float
), we extend the consumer associated with
the smallest primitive type that can represent the current type (e.g., int
or double
, respectively).
Consumer
Modifier and Type | Method and Description |
---|---|
void |
accept(byte t)
Performs this operation on the given input.
|
default void |
accept(java.lang.Byte t)
Deprecated.
Please use the corresponding type-specific method instead.
|
default void |
accept(int t)
Deprecated.
Please use the corresponding exact type-specific method instead.
|
default ByteConsumer |
andThen(ByteConsumer after)
Returns a composed type-specific consumer that performs, in sequence, this
operation followed by the
after operation. |
default java.util.function.Consumer<java.lang.Byte> |
andThen(java.util.function.Consumer<? super java.lang.Byte> after)
Deprecated.
Please use the corresponding type-specific method instead.
|
default ByteConsumer |
andThen(java.util.function.IntConsumer after) |
void accept(byte t)
t
- the input.@Deprecated default void accept(int t)
accept
in interface java.util.function.IntConsumer
@Deprecated default void accept(java.lang.Byte t)
accept
in interface java.util.function.Consumer<java.lang.Byte>
default ByteConsumer andThen(ByteConsumer after)
after
operation.after
- the operation to perform after this operation.Consumer
that performs in sequence this
operation followed by the after
operation.Consumer.andThen(java.util.function.Consumer<? super T>)
default ByteConsumer andThen(java.util.function.IntConsumer after)
andThen
in interface java.util.function.IntConsumer
@Deprecated default java.util.function.Consumer<java.lang.Byte> andThen(java.util.function.Consumer<? super java.lang.Byte> after)
andThen
in interface java.util.function.Consumer<java.lang.Byte>