Package | Description |
---|---|
java.util | |
java8.util |
Provides some of the new
java.util classes and implementations
of static and default interface methods added in Java 8. |
java8.util.concurrent |
The Java 7 and Java 8 utility classes commonly used in concurrent programming.
|
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 |
---|---|
DoubleStream |
Random.doubles()
Throws
AssertionError always. |
DoubleStream |
Random.doubles(double randomNumberOrigin,
double randomNumberBound)
Throws
AssertionError always. |
DoubleStream |
Random.doubles(long streamSize)
Throws
AssertionError always. |
DoubleStream |
Random.doubles(long streamSize,
double randomNumberOrigin,
double randomNumberBound)
Throws
AssertionError always. |
Modifier and Type | Method and Description |
---|---|
DoubleStream |
SplittableRandom.doubles()
Returns an effectively unlimited stream of pseudorandom
double values from this generator and/or one split from it; each value
is between zero (inclusive) and one (exclusive). |
DoubleStream |
SplittableRandom.doubles(double randomNumberOrigin,
double randomNumberBound)
Returns an effectively unlimited stream of pseudorandom
double values from this generator and/or one split from it; each value
conforms to the given origin (inclusive) and bound (exclusive). |
DoubleStream |
SplittableRandom.doubles(long streamSize)
Returns a stream producing the given
streamSize number of
pseudorandom double values from this generator and/or one split
from it; each value is between zero (inclusive) and one (exclusive). |
DoubleStream |
SplittableRandom.doubles(long streamSize,
double randomNumberOrigin,
double randomNumberBound)
Returns a stream producing the given
streamSize number of
pseudorandom double values from this generator and/or one split
from it; each value conforms to the given origin (inclusive) and bound
(exclusive). |
DoubleStream |
OptionalDouble.stream()
If a value is present return a sequential
DoubleStream containing
only that value, otherwise return an empty DoubleStream . |
static DoubleStream |
J8Arrays.stream(double[] array)
Returns a sequential
DoubleStream with the specified array as its
source. |
static DoubleStream |
J8Arrays.stream(double[] array,
int startInclusive,
int endExclusive)
Returns a sequential
DoubleStream with the specified range of the
specified array as its source. |
Modifier and Type | Method and Description |
---|---|
DoubleStream |
ThreadLocalRandom.doubles()
Returns an effectively unlimited stream of pseudorandom
double values, each between zero (inclusive) and one
(exclusive). |
DoubleStream |
ThreadLocalRandom.doubles(double randomNumberOrigin,
double randomNumberBound)
Returns an effectively unlimited stream of pseudorandom
double values, each conforming to the given origin (inclusive) and bound
(exclusive). |
DoubleStream |
ThreadLocalRandom.doubles(long streamSize)
Returns a stream producing the given
streamSize number of
pseudorandom double values, each between zero
(inclusive) and one (exclusive). |
DoubleStream |
ThreadLocalRandom.doubles(long streamSize,
double randomNumberOrigin,
double randomNumberBound)
Returns a stream producing the given
streamSize number of
pseudorandom double values, each conforming to the given origin
(inclusive) and bound (exclusive). |
Modifier and Type | Method and Description |
---|---|
DoubleStream |
LongStream.asDoubleStream()
Returns a
DoubleStream consisting of the elements of this stream,
converted to double . |
DoubleStream |
IntStream.asDoubleStream()
Returns a
DoubleStream consisting of the elements of this stream,
converted to double . |
DoubleStream |
DoubleStream.Builder.build()
Builds the stream, transitioning this builder to the built state.
|
static DoubleStream |
DoubleStreams.concat(DoubleStream a,
DoubleStream b)
Creates a lazily concatenated stream whose elements are all the
elements of the first stream followed by all the elements of the
second stream.
|
DoubleStream |
DoubleStream.distinct()
Returns a stream consisting of the distinct elements of this stream.
|
static DoubleStream |
StreamSupport.doubleStream(Spliterator.OfDouble spliterator,
boolean parallel)
Creates a new sequential or parallel
DoubleStream from a
Spliterator.OfDouble . |
static DoubleStream |
StreamSupport.doubleStream(Supplier<? extends Spliterator.OfDouble> supplier,
int characteristics,
boolean parallel)
Creates a new sequential or parallel
DoubleStream from a
Supplier of Spliterator.OfDouble . |
DoubleStream |
DoubleStream.dropWhile(DoublePredicate predicate)
Returns, if this stream is ordered, a stream consisting of the remaining
elements of this stream after dropping the longest prefix of elements
that match the given predicate.
|
static DoubleStream |
DoubleStreams.dropWhile(DoubleStream stream,
DoublePredicate predicate)
Returns a stream consisting of the remaining elements of the passed
stream after discarding elements that match the given predicate up to,
but not discarding, the first element encountered that does not match the
predicate.
|
static DoubleStream |
DoubleStreams.empty()
Returns an empty sequential
DoubleStream . |
DoubleStream |
DoubleStream.filter(DoublePredicate predicate)
Returns a stream consisting of the elements of this stream that match
the given predicate.
|
DoubleStream |
DoubleStream.flatMap(DoubleFunction<? extends DoubleStream> mapper)
Returns a stream consisting of the results of replacing each element of
this stream with the contents of a mapped stream produced by applying
the provided mapping function to each element.
|
DoubleStream |
Stream.flatMapToDouble(Function<? super T,? extends DoubleStream> mapper)
Returns an
DoubleStream consisting of the results of replacing
each element of this stream with the contents of a mapped stream produced
by applying the provided mapping function to each element. |
static DoubleStream |
DoubleStreams.generate(DoubleSupplier s)
Returns an infinite sequential unordered stream where each element is
generated by the provided
DoubleSupplier . |
static DoubleStream |
DoubleStreams.iterate(double seed,
DoubleUnaryOperator f)
Returns an infinite sequential ordered
DoubleStream produced by iterative
application of a function f to an initial element seed ,
producing a Stream consisting of seed , f(seed) ,
f(f(seed)) , etc. |
DoubleStream |
DoubleStream.limit(long maxSize)
Returns a stream consisting of the elements of this stream, truncated
to be no longer than
maxSize in length. |
DoubleStream |
DoubleStream.map(DoubleUnaryOperator mapper)
Returns a stream consisting of the results of applying the given
function to the elements of this stream.
|
DoubleStream |
IntStream.mapToDouble(IntToDoubleFunction mapper)
Returns a
DoubleStream consisting of the results of applying the
given function to the elements of this stream. |
DoubleStream |
LongStream.mapToDouble(LongToDoubleFunction mapper)
Returns a
DoubleStream consisting of the results of applying the
given function to the elements of this stream. |
DoubleStream |
Stream.mapToDouble(ToDoubleFunction<? super T> mapper)
Returns a
DoubleStream consisting of the results of applying the
given function to the elements of this stream. |
static DoubleStream |
DoubleStreams.of(double... values)
Returns a sequential ordered stream whose elements are the specified values.
|
static DoubleStream |
DoubleStreams.of(double t)
Returns a sequential
DoubleStream containing a single element. |
DoubleStream |
DoubleStream.parallel() |
DoubleStream |
DoubleStream.peek(DoubleConsumer 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.
|
DoubleStream |
DoubleStream.sequential() |
DoubleStream |
DoubleStream.skip(long n)
Returns a stream consisting of the remaining elements of this stream
after discarding the first
n elements of the stream. |
DoubleStream |
DoubleStream.sorted()
Returns a stream consisting of the elements of this stream in sorted
order.
|
DoubleStream |
DoubleStream.takeWhile(DoublePredicate predicate)
Returns, if this stream is ordered, a stream consisting of the longest
prefix of elements taken from this stream that match the given predicate.
|
static DoubleStream |
DoubleStreams.takeWhile(DoubleStream stream,
DoublePredicate predicate)
Returns a stream consisting of elements of the passed stream that match
the given predicate up to, but discarding, the first element encountered
that does not match the predicate.
|
Modifier and Type | Method and Description |
---|---|
static DoubleStream |
DoubleStreams.concat(DoubleStream a,
DoubleStream b)
Creates a lazily concatenated stream whose elements are all the
elements of the first stream followed by all the elements of the
second stream.
|
static DoubleStream |
DoubleStreams.dropWhile(DoubleStream stream,
DoublePredicate predicate)
Returns a stream consisting of the remaining elements of the passed
stream after discarding elements that match the given predicate up to,
but not discarding, the first element encountered that does not match the
predicate.
|
static DoubleStream |
DoubleStreams.takeWhile(DoubleStream stream,
DoublePredicate predicate)
Returns a stream consisting of elements of the passed stream that match
the given predicate up to, but discarding, the first element encountered
that does not match the predicate.
|
Modifier and Type | Method and Description |
---|---|
DoubleStream |
DoubleStream.flatMap(DoubleFunction<? extends DoubleStream> mapper)
Returns a stream consisting of the results of replacing each element of
this stream with the contents of a mapped stream produced by applying
the provided mapping function to each element.
|
DoubleStream |
Stream.flatMapToDouble(Function<? super T,? extends DoubleStream> mapper)
Returns an
DoubleStream consisting of the results of replacing
each element of this stream with the contents of a mapped stream produced
by applying the provided mapping function to each element. |
Copyright © 2015. All rights reserved.