Package | Description |
---|---|
java8.lang |
Provides classes for some of the new static methods that were added in Java 8.
|
java8.util |
Provides some of the new
java.util classes and implementations
of static and default interface methods added in Java 8. |
java8.util.function |
Functional interfaces provide target types for lambda expressions
and method references.
|
java8.util.stream |
Classes to support functional-style operations on streams of elements, such
as map-reduce transformations on collections.
|
Modifier and Type | Method and Description |
---|---|
static <T> void |
Iterables.forEach(Iterable<? extends T> it,
Consumer<? super T> action)
Performs the given action for each element of the passed
Iterable
until all elements have been processed or the action throws an
exception. |
Modifier and Type | Method and Description |
---|---|
void |
Spliterator.OfDouble.forEachRemaining(Consumer<? super Double> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterators.AbstractDoubleSpliterator.forEachRemaining(Consumer<? super Double> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterator.OfInt.forEachRemaining(Consumer<? super Integer> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterators.AbstractIntSpliterator.forEachRemaining(Consumer<? super Integer> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterator.OfLong.forEachRemaining(Consumer<? super Long> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterators.AbstractLongSpliterator.forEachRemaining(Consumer<? super Long> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterator.forEachRemaining(Consumer<? super T> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Spliterators.AbstractSpliterator.forEachRemaining(Consumer<? super T> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
static <E> void |
Iterators.forEachRemaining(Iterator<E> it,
Consumer<? super E> action)
Performs the given action for each remaining element until all elements
have been processed or the action throws an exception.
|
static void |
Spliterators.OfDouble.forEachRemaining(Spliterator.OfDouble this_,
Consumer<? super Double> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
static void |
Spliterators.OfInt.forEachRemaining(Spliterator.OfInt this_,
Consumer<? super Integer> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
static void |
Spliterators.OfLong.forEachRemaining(Spliterator.OfLong this_,
Consumer<? super Long> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
static <T> void |
Spliterators.forEachRemaining(Spliterator<T> this_,
Consumer<? super T> action)
Performs the given action for each remaining element, sequentially in
the current thread, until all elements have been processed or the action
throws an exception.
|
void |
Optional.ifPresent(Consumer<? super T> action)
If a value is present, performs the given action with the value,
otherwise does nothing.
|
void |
Optional.ifPresentOrElse(Consumer<? super T> action,
Runnable emptyAction)
If a value is present, performs the given action with the value,
otherwise performs the given empty-based action.
|
boolean |
Spliterator.OfDouble.tryAdvance(Consumer<? super Double> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterators.AbstractDoubleSpliterator.tryAdvance(Consumer<? super Double> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterator.OfInt.tryAdvance(Consumer<? super Integer> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterators.AbstractIntSpliterator.tryAdvance(Consumer<? super Integer> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterator.OfLong.tryAdvance(Consumer<? super Long> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterators.AbstractLongSpliterator.tryAdvance(Consumer<? super Long> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
boolean |
Spliterator.tryAdvance(Consumer<? super T> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
static boolean |
Spliterators.OfDouble.tryAdvance(Spliterator.OfDouble this_,
Consumer<? super Double> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
static boolean |
Spliterators.OfInt.tryAdvance(Spliterator.OfInt this_,
Consumer<? super Integer> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
static boolean |
Spliterators.OfLong.tryAdvance(Spliterator.OfLong this_,
Consumer<? super Long> action)
If a remaining element exists, performs the given action on it,
returning
true ; else returns false . |
Modifier and Type | Method and Description |
---|---|
static <T> Consumer<T> |
Consumers.andThen(Consumer<? super T> this_,
Consumer<? super T> after)
Returns a composed
Consumer that performs, in sequence, the this_
operation followed by the after operation. |
Modifier and Type | Method and Description |
---|---|
static <T> Consumer<T> |
Consumers.andThen(Consumer<? super T> this_,
Consumer<? super T> after)
Returns a composed
Consumer that performs, in sequence, the this_
operation followed by the after operation. |
static <T> Consumer<T> |
Consumers.andThen(Consumer<? super T> this_,
Consumer<? super T> after)
Returns a composed
Consumer that performs, in sequence, the this_
operation followed by the after operation. |
Modifier and Type | Interface and Description |
---|---|
static interface |
Stream.Builder<T>
A mutable builder for a
Stream . |
Modifier and Type | Method and Description |
---|---|
void |
Stream.forEach(Consumer<? super T> action)
Performs an action for each element of this stream.
|
void |
Stream.forEachOrdered(Consumer<? super T> action)
Performs an action for each element of this stream, in the encounter
order of the stream if the stream has a defined encounter order.
|
Stream<T> |
Stream.peek(Consumer<? super T> action)
Returns a stream consisting of the elements of this stream, additionally
performing the provided action on each element as elements are consumed
from the resulting stream.
|
Copyright © 2016. All rights reserved.