| Package | Description |
|---|---|
| com.annimon.stream |
| Modifier and Type | Method and Description |
|---|---|
static <T> Stream<T> |
Stream.concat(Stream<? extends T> stream1,
Stream<? extends T> stream2)
Concatenates two streams.
|
Stream<T> |
Stream.distinct()
Returns
Stream with distinct elements (as determinated by equals method). |
Stream<T> |
Stream.filter(Predicate<? super T> predicate)
Returns
Stream with elements that satisfy the given predicate. |
<R> Stream<R> |
Stream.flatMap(Function<? super T,? extends Stream<? extends R>> mapper)
Generates
Stream by concatenating elements that obtained by applying the given function. |
static <T> Stream<T> |
Stream.generate(Supplier<T> supplier)
Creates a
Stream by elements that generated by Supplier. |
<K> Stream<Map.Entry<K,List<T>>> |
Stream.groupBy(Function<? super T,? extends K> classifier)
Partitions
Stream into Map entries according to the given classifier function. |
static <T> Stream<T> |
Stream.iterate(T seed,
UnaryOperator<T> op)
Creates a
Stream by applying UnaryOperator operation to an initial element seed. |
Stream<T> |
Stream.limit(long maxSize)
Returns
Stream with first maxSize elements. |
<R> Stream<R> |
Stream.map(Function<? super T,? extends R> mapper)
Returns
Stream with elements that obtained by applying the given function. |
static <T> Stream<T> |
Stream.of(Iterable<? extends T> iterable)
Creates a
Stream from any class that implements Iterable interface. |
static <T> Stream<T> |
Stream.of(Iterator<? extends T> iterator)
Creates a
Stream from any class that implements Iterator interface. |
static <T> Stream<T> |
Stream.of(List<? extends T> list)
Creates a
Stream from List. |
static <K,V> Stream<Map.Entry<K,V>> |
Stream.of(Map<K,V> map)
Creates a
Stream from Map entries. |
static <T> Stream<T> |
Stream.of(T... elements)
Creates a
Stream from the specified values. |
static Stream<Integer> |
Stream.ofRange(int from,
int to)
Creates a
Stream<Integer> from not closed range
(from from inclusive to to exclusive and incremental step 1). |
static Stream<Long> |
Stream.ofRange(long from,
long to)
Creates a
Stream<Long> from not closed range
(from from inclusive to to exclusive and incremental step 1). |
static Stream<Integer> |
Stream.ofRangeClosed(int from,
int to)
Creates a
Stream<Integer> from closed range
(from from inclusive to to inclusive and incremental step 1). |
static Stream<Long> |
Stream.ofRangeClosed(long from,
long to)
Creates a
Stream<Long> from closed range
(from from inclusive to to inclusive and incremental step 1). |
Stream<T> |
Stream.peek(Consumer<? super T> action)
Perform provided action to each elements.
|
Stream<T> |
Stream.skip(long n)
Skips first
n elements and returns Stream with remaining elements. |
<R extends Comparable> |
Stream.sortBy(Function<? super T,? extends R> f)
Returns
Stream with sorted elements (as determinated by Comparable interface). |
Stream<T> |
Stream.sorted()
Returns
Stream with sorted elements (as determinated by Comparable interface). |
Stream<T> |
Stream.sorted(Comparator<? super T> comparator)
Returns
Stream with sorted elements (as determinated by provided Comparator). |
| Modifier and Type | Method and Description |
|---|---|
static <T> Stream<T> |
Stream.concat(Stream<? extends T> stream1,
Stream<? extends T> stream2)
Concatenates two streams.
|
static <T> Stream<T> |
Stream.concat(Stream<? extends T> stream1,
Stream<? extends T> stream2)
Concatenates two streams.
|
| Modifier and Type | Method and Description |
|---|---|
<R> R |
Stream.custom(Function<Stream<T>,R> function)
Applies custom operator on stream.
|
<R> Stream<R> |
Stream.flatMap(Function<? super T,? extends Stream<? extends R>> mapper)
Generates
Stream by concatenating elements that obtained by applying the given function. |
Copyright © 2015. All rights reserved.