Uses of Interface
java.util.stream.Gatherer
Packages that use Gatherer
Package
Description
Classes to support functional-style operations on streams of elements, such
as map-reduce transformations on collections.
-
Uses of Gatherer in java.util.stream
Methods in java.util.stream that return GathererModifier and TypeMethodDescriptionReturns a composed Gatherer which connects the output of this Gatherer to the input of that Gatherer.static <T,R> Gatherer <T, ?, R> Gatherers.fold(Supplier<R> initial, BiFunction<? super R, ? super T, ? extends R> folder) Returns a Gatherer that performs an ordered, reduction-like, transformation for scenarios where no combiner-function can be implemented, or for reductions which are intrinsically order-dependent.static <T,R> Gatherer <T, ?, R> Gatherers.mapConcurrent(int maxConcurrency, Function<? super T, ? extends R> mapper) An operation which executes a function concurrently with a configured level of max concurrency, using virtual threads.static <T,A, R> Gatherer <T, A, R> Gatherer.of(Supplier<A> initializer, Gatherer.Integrator<A, T, R> integrator, BinaryOperator<A> combiner, BiConsumer<A, Gatherer.Downstream<? super R>> finisher) Returns a new, parallelizable,Gathererdescribed by the giveninitializer,integrator,combinerandfinisher.Gatherer.of(Gatherer.Integrator<Void, T, R> integrator) Returns a new, parallelizable, and statelessGathererdescribed by the givenintegrator.Gatherer.of(Gatherer.Integrator<Void, T, R> integrator, BiConsumer<Void, Gatherer.Downstream<? super R>> finisher) Returns a new, parallelizable, and statelessGathererdescribed by the givenintegratorandfinisher.static <T,A, R> Gatherer <T, A, R> Gatherer.ofSequential(Supplier<A> initializer, Gatherer.Integrator<A, T, R> integrator) Returns a new, sequential,Gathererdescribed by the giveninitializerandintegrator.static <T,A, R> Gatherer <T, A, R> Gatherer.ofSequential(Supplier<A> initializer, Gatherer.Integrator<A, T, R> integrator, BiConsumer<A, Gatherer.Downstream<? super R>> finisher) Returns a new, sequential,Gathererdescribed by the giveninitializer,integrator, andfinisher.Gatherer.ofSequential(Gatherer.Integrator<Void, T, R> integrator) Returns a new, sequential, and statelessGathererdescribed by the givenintegrator.Gatherer.ofSequential(Gatherer.Integrator<Void, T, R> integrator, BiConsumer<Void, Gatherer.Downstream<? super R>> finisher) Returns a new, sequential, and statelessGathererdescribed by the givenintegratorandfinisher.static <T,R> Gatherer <T, ?, R> Gatherers.scan(Supplier<R> initial, BiFunction<? super R, ? super T, ? extends R> scanner) Returns a Gatherer that performs a Prefix Scan -- an incremental accumulation -- using the provided functions.Gatherers.windowFixed(int windowSize) Returns a Gatherer that gathers elements into windows -- encounter-ordered groups of elements -- of a fixed size.Gatherers.windowSliding(int windowSize) Returns a Gatherer that gathers elements into windows -- encounter-ordered groups of elements -- of a given size, where each subsequent window includes all elements of the previous window except for the least recent, and adds the next element in the stream.Methods in java.util.stream with parameters of type Gatherer