A Repository for commons utilities implementations for Reactive Streams.
I.e., converts non-reactive data sources into Publisher
s.
PublisherAmb
: relays signals of that source Publisher which responds first with any signalPublisherArray
: emits the elements of an arrayPublisherCallable
: emits a single value returned by aCallable
PublisherCompletableFuture
: emits a single value produced by aCompletableFuture
PublisherConcatArray
: concatenate an array ofPublisher
sPublisherConcatIterable
: concatenate anIterable
sequence ofPublisher
sPublisherDefer
: calls aSupplier
to create the actualPublisher
theSubscriber
will be subscribed to.PublisherEmpty
: does not emit any value and callsonCompleted
; useinstance()
to get its singleton instance with the proper type parameterPublisherError
: emits a constant or generated Throwable exceptionPublisherGenerate
: generate signals one-by-one via a functionPublisherIterable
: emits the elements of anIterable
PublisherJust
: emits a single valuePublisherNever
: doesn't emit any signal other thanonSubscribe
; useinstance()
to get its singleton instance with the proper type parameterPublisherRange
: emits a range of integer valuesPublisherStream
: emits elements of aStream
PublisherUsing
: create a resource, stream values in a Publisher derived from the resource and release the resource when the sequence completes or the Subscriber cancels
PublisherAccumulate
: Accumulates the source values with an accumulator function and returns the intermediate results of this function applicationPublisherAll
: emits a single true if all values of the source sequence match the predicatePublisherAny
: emits a single true if any value of the source sequence matches the predicatePublisherBuffer
: buffers certain number of subsequent elements and emits the buffersPublisherCollect
: collects the values into a container and emits it when the source completesPublisherCount
: counts the number of elements the source sequence emitsPublisherDistinct
: filters out elements that have been seen previously according to a custom collectionPublisherDistinctUntilChanged
: filters out subsequent and repeated elementsPublisherDefaultIfEmpty
: emits a single value if the source is emptyPublisherDelaySubscription
: delays the subscription to the main source until the other source signals a value or completesPublisherDrop
: runs the source in unbounded mode and drops values if the downstream doesn't request fast enoughPublisherElementAt
: emits the element at the specified index locationPublisherFilter
: filters out values which doesn't pass a predicatePublisherIsEmpty
: returns a single true if the source sequence is emptyPublisherLatest
: runs the source in unbounded mode and emits the latest value if the downstream doesn't request fast enoughPublisherLift
: maps the downstream Subscriber into an upstream Subscriber which allows implementing custom operators via lambdasPublisherMap
: map values to other values via a functionPublisherPeek
: peek into the lifecycle and signals of a streamPublisherReduce
: aggregates the source values with the help of an accumulator function and emits the the final accumulated valuePublisherRepeat
: repeatedly streams the source sequence fixed or unlimited timesPublisherResume
: if the source fails, the stream is resumed by another Publisher returned by a function for the failure exceptionPublisherRetry
: retry a failed source sequence fixed or unlimited timesPublisherSample
: samples the main source whenever the other Publisher signals a valuePublisherScan
: aggregates the source values with the help of an accumulator function and emits the intermediate resultsPublisherSingle
: expects the source to emit only a single itemPublisherSkip
: skips a specified amount of valuesPublisherSkipLast
: skips the last N elementsPublisherSkipUntil
: skips values until another sequence signals a value or completesPublisherSkipWhile
skips values while the predicate returns truePublisherSwitchIfEmpty
: continues with another sequence if the first sequence turns out to be empty.PublisherTake
: takes a specified amount of values and completesPublisherTakeLast
: emits only the last N values the source emitted before its completionPublisherTakeWhile
: relays values while a predicate returns true for the values (checked before each value)PublisherTakeUntil
: relays values until another Publisher signalsPublisherTakeUntilPredicate
: relays values until a predicate returns true (checked after each value)PublisherWithLatestFrom
: combines values from a master source with the latest values of another Publisher via a function
I.e., these allow leaving the reactive-streams world.