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.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> Spliterator<T> |
Iterables.spliterator(Iterable<? extends T> it)
Creates a
Spliterator over the elements described by this
Iterable . |
Modifier and Type | Interface and Description |
---|---|
static interface |
Spliterator.OfDouble
A Spliterator specialized for
double values. |
static interface |
Spliterator.OfInt
A Spliterator specialized for
int values. |
static interface |
Spliterator.OfLong
A Spliterator specialized for
long values. |
static interface |
Spliterator.OfPrimitive<T,T_CONS,T_SPLITR extends Spliterator.OfPrimitive<T,T_CONS,T_SPLITR>>
A Spliterator specialized for primitive values.
|
Modifier and Type | Class and Description |
---|---|
static class |
Spliterators.AbstractDoubleSpliterator
An abstract
Spliterator.OfDouble that implements
trySplit to permit limited parallelism. |
static class |
Spliterators.AbstractIntSpliterator
An abstract
Spliterator.OfInt that implements trySplit to
permit limited parallelism. |
static class |
Spliterators.AbstractLongSpliterator
An abstract
Spliterator.OfLong that implements trySplit
to permit limited parallelism. |
static class |
Spliterators.AbstractSpliterator<T>
An abstract
Spliterator that implements trySplit to
permit limited parallelism. |
Modifier and Type | Method and Description |
---|---|
static <T> Spliterator<T> |
Spliterators.emptySpliterator()
|
static <T> Spliterator<T> |
Spliterators.spliterator(Collection<? extends T> c)
Creates either a specialized
Spliterator (effectively the same
one that Java 8 uses) for the given collection provided it is one of the
types listed below or a Spliterator using the given collection's
Collection.iterator() as the source of elements, and
reporting its Collection.size() as its initial size. |
static <T> Spliterator<T> |
Spliterators.spliterator(Collection<? extends T> c,
int characteristics)
Creates a
Spliterator using the given collection's
Collection.iterator() as the source of elements, and
reporting its Collection.size() as its initial size. |
static <T> Spliterator<T> |
Spliterators.spliterator(Iterator<? extends T> iterator,
long size,
int characteristics)
Creates a
Spliterator using a given Iterator
as the source of elements, and with a given initially reported size. |
static <E> Spliterator<E> |
Lists.spliterator(List<E> list)
Creates a
Spliterator over the elements in the passed list. |
static <T> Spliterator<T> |
Spliterators.spliterator(Object[] array,
int additionalCharacteristics)
Creates a
Spliterator covering the elements of a given array,
using a customized set of spliterator characteristics. |
static <T> Spliterator<T> |
Spliterators.spliterator(Object[] array,
int fromIndex,
int toIndex,
int additionalCharacteristics)
Creates a
Spliterator covering a range of elements of a given
array, using a customized set of spliterator characteristics. |
static <T> Spliterator<T> |
J8Arrays.spliterator(T[] array)
Returns a
Spliterator covering all of the specified array. |
static <T> Spliterator<T> |
J8Arrays.spliterator(T[] array,
int startInclusive,
int endExclusive)
Returns a
Spliterator covering the specified range of the
specified array. |
static <T> Spliterator<T> |
Spliterators.spliteratorUnknownSize(Iterator<? extends T> iterator,
int characteristics)
Creates a
Spliterator using a given Iterator
as the source of elements, with no initial size estimate. |
Spliterator<T> |
Spliterators.AbstractSpliterator.trySplit()
If this spliterator can be partitioned, returns a Spliterator
covering elements, that will, upon return from this method, not
be covered by this Spliterator.
|
Spliterator<T> |
Spliterator.trySplit()
If this spliterator can be partitioned, returns a Spliterator
covering elements, that will, upon return from this method, not
be covered by this Spliterator.
|
Modifier and Type | Method and Description |
---|---|
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.
|
static <T> Comparator<? super T> |
Spliterators.getComparator(Spliterator<T> this_)
|
static <T> long |
Spliterators.getExactSizeIfKnown(Spliterator<T> this_)
|
static <T> boolean |
Spliterators.hasCharacteristics(Spliterator<T> this_,
int characteristics)
|
static <T> Iterator<T> |
Spliterators.iterator(Spliterator<? extends T> spliterator)
Creates an
Iterator from a Spliterator . |
Modifier and Type | Method and Description |
---|---|
Spliterator<T> |
BaseStream.spliterator()
Returns a spliterator for the elements of this stream.
|
Modifier and Type | Method and Description |
---|---|
static <T> Stream<T> |
StreamSupport.stream(Spliterator<T> spliterator,
boolean parallel)
Creates a new sequential or parallel
Stream from a
Spliterator . |
Modifier and Type | Method and Description |
---|---|
static <T> Stream<T> |
StreamSupport.stream(Supplier<? extends Spliterator<T>> supplier,
int characteristics,
boolean parallel)
Creates a new sequential or parallel
Stream from a
Supplier of Spliterator . |
Copyright © 2016. All rights reserved.