Class ParallelCollect<T,C>
java.lang.Object
io.reactivex.rxjava3.parallel.ParallelFlowable<C>
io.reactivex.rxjava3.internal.operators.parallel.ParallelCollect<T,C>
- Type Parameters:
T- the input value typeC- the collection type
Reduce the sequence of values in each 'rail' to a single value.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static final class -
Field Summary
FieldsModifier and TypeFieldDescription(package private) final BiConsumer<? super C, ? super T> (package private) final ParallelFlowable<? extends T> -
Constructor Summary
ConstructorsConstructorDescriptionParallelCollect(ParallelFlowable<? extends T> source, Supplier<? extends C> initialCollection, BiConsumer<? super C, ? super T> collector) -
Method Summary
Modifier and TypeMethodDescriptionintReturns the number of expected parallelSubscribers.(package private) voidreportError(org.reactivestreams.Subscriber<?>[] subscribers, Throwable ex) voidSubscribes an array ofSubscribers to thisParallelFlowableand triggers the execution chain for all 'rails'.Methods inherited from class io.reactivex.rxjava3.parallel.ParallelFlowable
collect, collect, compose, concatMap, concatMap, concatMapDelayError, concatMapDelayError, doAfterNext, doAfterTerminated, doOnCancel, doOnComplete, doOnError, doOnNext, doOnNext, doOnNext, doOnRequest, doOnSubscribe, filter, filter, filter, flatMap, flatMap, flatMap, flatMap, flatMapIterable, flatMapIterable, flatMapStream, flatMapStream, from, from, from, fromArray, map, map, map, mapOptional, mapOptional, mapOptional, reduce, reduce, runOn, runOn, sequential, sequential, sequentialDelayError, sequentialDelayError, sorted, sorted, to, toSortedList, toSortedList, validate
-
Field Details
-
source
-
initialCollection
-
collector
-
-
Constructor Details
-
ParallelCollect
public ParallelCollect(ParallelFlowable<? extends T> source, Supplier<? extends C> initialCollection, BiConsumer<? super C, ? super T> collector)
-
-
Method Details
-
subscribe
Description copied from class:ParallelFlowableSubscribes an array ofSubscribers to thisParallelFlowableand triggers the execution chain for all 'rails'.- Backpressure:
- The backpressure behavior/expectation is determined by the supplied
Subscriber. - Scheduler:
subscribedoes not operate by default on a particularScheduler.
- Specified by:
subscribein classParallelFlowable<C>- Parameters:
subscribers- the subscribers array to run in parallel, the number of items must be equal to the parallelism level of thisParallelFlowable- See Also:
-
reportError
-
parallelism
public int parallelism()Description copied from class:ParallelFlowableReturns the number of expected parallelSubscribers.- Specified by:
parallelismin classParallelFlowable<C>- Returns:
- the number of expected parallel
Subscribers
-