| Package | Description |
|---|---|
| com.annimon.stream |
| Modifier and Type | Method and Description |
|---|---|
Supplier<A> |
Collector.supplier()
Function provides new containers.
|
| Modifier and Type | Method and Description |
|---|---|
<R> R |
Stream.collect(Supplier<R> supplier,
BiConsumer<R,? super T> accumulator)
Collects elements to
supplier provided container by applying the given accumulation function. |
<R> R |
DoubleStream.collect(Supplier<R> supplier,
ObjDoubleConsumer<R> accumulator)
Collects elements to
supplier provided container by applying the given accumulation function. |
<R> R |
IntStream.collect(Supplier<R> supplier,
ObjIntConsumer<R> accumulator)
Collects elements to
supplier provided container by applying the given accumulation function. |
<R> R |
LongStream.collect(Supplier<R> supplier,
ObjLongConsumer<R> accumulator)
Collects elements to
supplier provided container by applying the given accumulation function. |
static <T> Stream<T> |
Stream.generate(Supplier<T> supplier)
Creates a
Stream by elements that generated by Supplier. |
static <T,K,D,A,M extends Map<K,D>> |
Collectors.groupingBy(Function<? super T,? extends K> classifier,
Supplier<M> mapFactory,
Collector<? super T,A,D> downstream)
Returns a
Collector that performs grouping operation by given classifier. |
Exceptional<T> |
Exceptional.or(Supplier<Exceptional<T>> supplier)
Returns current
Exceptional if there were no exceptions, otherwise
returns an Exceptional produced by supplier function. |
Optional<T> |
Optional.or(Supplier<Optional<T>> supplier)
Returns current
Optional if value is present, otherwise
returns an Optional produced by supplier function. |
OptionalDouble |
OptionalDouble.or(Supplier<OptionalDouble> supplier)
Returns current
OptionalDouble if value is present, otherwise
returns an OptionalDouble produced by supplier function. |
OptionalInt |
OptionalInt.or(Supplier<OptionalInt> supplier)
Returns current
OptionalInt if value is present, otherwise
returns an OptionalInt produced by supplier function. |
OptionalLong |
OptionalLong.or(Supplier<OptionalLong> supplier)
Returns current
OptionalLong if value is present, otherwise
returns an OptionalLong produced by supplier function. |
T |
Optional.orElseGet(Supplier<? extends T> other)
Returns inner value if present, otherwise returns value produced by supplier function.
|
<X extends Throwable> |
Optional.orElseThrow(Supplier<? extends X> exc)
Returns inner value if present, otherwise throws the exception provided by supplier function.
|
<X extends Throwable> |
OptionalLong.orElseThrow(Supplier<X> exceptionSupplier)
Returns the value if present, otherwise throws an exception provided by supplier function.
|
<X extends Throwable> |
OptionalInt.orElseThrow(Supplier<X> exceptionSupplier)
Returns the value if present, otherwise throws an exception provided by supplier function.
|
<X extends Throwable> |
OptionalDouble.orElseThrow(Supplier<X> exceptionSupplier)
Returns the value if present, otherwise throws an exception provided by supplier function.
|
static <T,R extends Collection<T>> |
Collectors.toCollection(Supplier<R> collectionSupplier)
Returns a
Collector that fills new Collection, provided by collectionSupplier,
with input elements. |
static <T,K,V,M extends Map<K,V>> |
Collectors.toMap(Function<? super T,? extends K> keyMapper,
Function<? super T,? extends V> valueMapper,
Supplier<M> mapFactory)
Returns a
Collector that fills new Map with input elements. |
Copyright © 2017. All rights reserved.