程序包 | 说明 |
---|---|
reactor.adapter |
Adapt
Publisher to Java 9+
Flow.Publisher . |
reactor.core.publisher | |
reactor.guide | |
reactor.test |
Main test components supporting the testing and assertion of publishers.
|
reactor.test.publisher |
Components supporting the creation of test-oriented
Publishers . |
reactor.util.retry |
限定符和类型 | 方法和说明 |
---|---|
static <T> Flux<T> |
JdkFlowAdapter.flowPublisherToFlux(java.util.concurrent.Flow.Publisher<T> publisher)
Return a
Flux from a java Flow.Publisher |
限定符和类型 | 类和说明 |
---|---|
class |
ConnectableFlux<T>
The abstract base class for connectable publishers that let subscribers pile up
before they connect to their data source.
|
class |
DirectProcessor<T>
已过时。
To be removed in 3.5, prefer clear cut usage of
Sinks . Closest sink
is Sinks.many().multicast().directBestEffort() ,
except it doesn't terminate overflowing downstreams. |
class |
EmitterProcessor<T>
已过时。
To be removed in 3.5. Prefer clear cut usage of
Sinks through
variations of Sinks.many().multicast().onBackpressureBuffer() .
If you really need the subscribe-to-upstream functionality of a Processor , switch
to Sinks.ManyWithUpstream with Sinks.unsafe() variants of Sinks.unsafe().manyWithUpstream() .
This processor was blocking in EmitterProcessor.onNext(Object) . This behaviour can be implemented with the Sinks API by calling
Sinks.Many.tryEmitNext(Object) and retrying, e.g.:
|
class |
FluxOperator<I,O>
|
class |
FluxProcessor<IN,OUT>
已过时。
Processors will be removed in 3.5. Prefer using
Sinks.Many instead,
or see https://github.com/reactor/reactor-core/issues/2431 for alternatives |
class |
GroupedFlux<K,V>
Represents a sequence of events which has an associated key.
|
class |
ReplayProcessor<T>
已过时。
To be removed in 3.5, prefer clear cut usage of
Sinks through
variations under Sinks.many().replay() . |
class |
UnicastProcessor<T>
已过时。
to be removed in 3.5, prefer clear cut usage of
Sinks through
variations under Sinks.many().unicast() . |
限定符和类型 | 方法和说明 |
---|---|
Flux<T> |
EmitterProcessor.asFlux()
已过时。
|
Flux<T> |
ReplayProcessor.asFlux()
已过时。
|
Flux<T> |
UnicastProcessor.asFlux()
已过时。
|
Flux<T> |
Sinks.Many.asFlux()
Return a
Flux view of this sink. |
Flux<T> |
ConnectableFlux.autoConnect()
Connects this
ConnectableFlux to the upstream source when the first Subscriber
subscribes. |
Flux<T> |
ConnectableFlux.autoConnect(int minSubscribers)
Connects this
ConnectableFlux to the upstream source when the specified amount of
Subscriber subscribes. |
Flux<T> |
ConnectableFlux.autoConnect(int minSubscribers,
java.util.function.Consumer<? super Disposable> cancelSupport)
Connects this
ConnectableFlux to the upstream source when the specified amount of
Subscriber subscribes and calls the supplied consumer with a Disposable
that allows disconnecting. |
Flux<java.util.List<T>> |
Flux.buffer()
Collect all incoming values into a single
List buffer that will be emitted
by the returned Flux once this Flux completes. |
Flux<java.util.List<T>> |
Flux.buffer(java.time.Duration bufferingTimespan)
Collect incoming values into multiple
List buffers that will be emitted by
the returned Flux every bufferingTimespan . |
Flux<java.util.List<T>> |
Flux.buffer(java.time.Duration bufferingTimespan,
java.time.Duration openBufferEvery)
Collect incoming values into multiple
List buffers created at a given
openBufferEvery period. |
Flux<java.util.List<T>> |
Flux.buffer(java.time.Duration bufferingTimespan,
java.time.Duration openBufferEvery,
Scheduler timer)
Collect incoming values into multiple
List buffers created at a given
openBufferEvery period, as measured on the provided Scheduler . |
Flux<java.util.List<T>> |
Flux.buffer(java.time.Duration bufferingTimespan,
Scheduler timer)
|
Flux<java.util.List<T>> |
Flux.buffer(int maxSize)
Collect incoming values into multiple
List buffers that will be emitted
by the returned Flux each time the given max size is reached or once this
Flux completes. |
Flux<java.util.List<T>> |
Flux.buffer(int maxSize,
int skip)
Collect incoming values into multiple
List buffers that will be emitted
by the returned Flux each time the given max size is reached or once this
Flux completes. |
<C extends java.util.Collection<? super T>> |
Flux.buffer(int maxSize,
int skip,
java.util.function.Supplier<C> bufferSupplier)
Collect incoming values into multiple user-defined
Collection buffers that
will be emitted by the returned Flux each time the given max size is reached
or once this Flux completes. |
<C extends java.util.Collection<? super T>> |
Flux.buffer(int maxSize,
java.util.function.Supplier<C> bufferSupplier)
Collect incoming values into multiple user-defined
Collection buffers that
will be emitted by the returned Flux each time the given max size is reached
or once this Flux completes. |
Flux<java.util.List<T>> |
Flux.buffer(org.reactivestreams.Publisher<?> other)
Collect incoming values into multiple
List buffers, as delimited by the
signals of a companion Publisher this operator will subscribe to. |
<C extends java.util.Collection<? super T>> |
Flux.buffer(org.reactivestreams.Publisher<?> other,
java.util.function.Supplier<C> bufferSupplier)
Collect incoming values into multiple user-defined
Collection buffers, as
delimited by the signals of a companion Publisher this operator will
subscribe to. |
Flux<java.util.List<T>> |
Flux.bufferTimeout(int maxSize,
java.time.Duration maxTime)
Collect incoming values into multiple
List buffers that will be emitted
by the returned Flux each time the buffer reaches a maximum size OR the
maxTime Duration elapses. |
Flux<java.util.List<T>> |
Flux.bufferTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer)
|
<C extends java.util.Collection<? super T>> |
Flux.bufferTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer,
java.util.function.Supplier<C> bufferSupplier)
|
<C extends java.util.Collection<? super T>> |
Flux.bufferTimeout(int maxSize,
java.time.Duration maxTime,
java.util.function.Supplier<C> bufferSupplier)
Collect incoming values into multiple user-defined
Collection buffers that
will be emitted by the returned Flux each time the buffer reaches a maximum
size OR the maxTime Duration elapses. |
Flux<java.util.List<T>> |
Flux.bufferUntil(java.util.function.Predicate<? super T> predicate)
Collect incoming values into multiple
List buffers that will be emitted by
the resulting Flux each time the given predicate returns true. |
Flux<java.util.List<T>> |
Flux.bufferUntil(java.util.function.Predicate<? super T> predicate,
boolean cutBefore)
Collect incoming values into multiple
List buffers that will be emitted by
the resulting Flux each time the given predicate returns true. |
Flux<java.util.List<T>> |
Flux.bufferUntilChanged()
Collect subsequent repetitions of an element (that is, if they arrive right after
one another) into multiple
List buffers that will be emitted by the
resulting Flux . |
<V> Flux<java.util.List<T>> |
Flux.bufferUntilChanged(java.util.function.Function<? super T,? extends V> keySelector)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function , into multiple List buffers that will be emitted by the
resulting Flux . |
<V> Flux<java.util.List<T>> |
Flux.bufferUntilChanged(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.BiPredicate<? super V,? super V> keyComparator)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function and compared using a supplied BiPredicate , into multiple
List buffers that will be emitted by the resulting Flux . |
<U,V> Flux<java.util.List<T>> |
Flux.bufferWhen(org.reactivestreams.Publisher<U> bucketOpening,
java.util.function.Function<? super U,? extends org.reactivestreams.Publisher<V>> closeSelector)
Collect incoming values into multiple
List buffers started each time an opening
companion Publisher emits. |
<U,V,C extends java.util.Collection<? super T>> |
Flux.bufferWhen(org.reactivestreams.Publisher<U> bucketOpening,
java.util.function.Function<? super U,? extends org.reactivestreams.Publisher<V>> closeSelector,
java.util.function.Supplier<C> bufferSupplier)
Collect incoming values into multiple user-defined
Collection buffers started each time an opening
companion Publisher emits. |
Flux<java.util.List<T>> |
Flux.bufferWhile(java.util.function.Predicate<? super T> predicate)
Collect incoming values into multiple
List buffers that will be emitted by
the resulting Flux . |
Flux<T> |
Flux.cache()
Turn this
Flux into a hot source and cache last emitted signals for further Subscriber . |
Flux<T> |
Flux.cache(java.time.Duration ttl)
Turn this
Flux into a hot source and cache last emitted signals for further
Subscriber . |
Flux<T> |
Flux.cache(java.time.Duration ttl,
Scheduler timer)
Turn this
Flux into a hot source and cache last emitted signals for further
Subscriber . |
Flux<T> |
Flux.cache(int history)
Turn this
Flux into a hot source and cache last emitted signals for further Subscriber . |
Flux<T> |
Flux.cache(int history,
java.time.Duration ttl)
Turn this
Flux into a hot source and cache last emitted signals for further
Subscriber . |
Flux<T> |
Flux.cache(int history,
java.time.Duration ttl,
Scheduler timer)
Turn this
Flux into a hot source and cache last emitted signals for further
Subscriber . |
Flux<T> |
Flux.cancelOn(Scheduler scheduler)
|
<E> Flux<E> |
Flux.cast(java.lang.Class<E> clazz)
Cast the current
Flux produced type into a target produced type. |
Flux<T> |
Flux.checkpoint()
Activate traceback (full assembly tracing) for this particular
Flux , in case of an error
upstream of the checkpoint. |
Flux<T> |
Flux.checkpoint(java.lang.String description)
Activate traceback (assembly marker) for this particular
Flux by giving it a description that
will be reflected in the assembly traceback in case of an error upstream of the
checkpoint. |
Flux<T> |
Flux.checkpoint(java.lang.String description,
boolean forceStackTrace)
Activate traceback (full assembly tracing or the lighter assembly marking depending on the
forceStackTrace option). |
static <T,V> Flux<V> |
Flux.combineLatest(java.util.function.Function<java.lang.Object[],V> combinator,
int prefetch,
org.reactivestreams.Publisher<? extends T>... sources)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of the Publisher sources. |
static <T,V> Flux<V> |
Flux.combineLatest(java.util.function.Function<java.lang.Object[],V> combinator,
org.reactivestreams.Publisher<? extends T>... sources)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of the Publisher sources. |
static <T,V> Flux<V> |
Flux.combineLatest(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends T>> sources,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each
of the Publisher sources provided in an Iterable . |
static <T,V> Flux<V> |
Flux.combineLatest(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends T>> sources,
int prefetch,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each
of the Publisher sources provided in an Iterable . |
static <T1,T2,V> Flux<V> |
Flux.combineLatest(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
java.util.function.BiFunction<? super T1,? super T2,? extends V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of two Publisher sources. |
static <T1,T2,T3,V> |
Flux.combineLatest(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of three Publisher sources. |
static <T1,T2,T3,T4,V> |
Flux.combineLatest(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of four Publisher sources. |
static <T1,T2,T3,T4,T5,V> |
Flux.combineLatest(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of five Publisher sources. |
static <T1,T2,T3,T4,T5,T6,V> |
Flux.combineLatest(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5,
org.reactivestreams.Publisher<? extends T6> source6,
java.util.function.Function<java.lang.Object[],V> combinator)
Build a
Flux whose data are generated by the combination of the
most recently published value from each of six Publisher sources. |
static <T> Flux<T> |
Flux.concat(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends T>> sources)
Concatenate all sources provided in an
Iterable , forwarding elements
emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concat(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources)
Concatenate all sources emitted as an onNext signal from a parent
Publisher ,
forwarding elements emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concat(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources,
int prefetch)
Concatenate all sources emitted as an onNext signal from a parent
Publisher ,
forwarding elements emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concat(org.reactivestreams.Publisher<? extends T>... sources)
Concatenate all sources provided as a vararg, forwarding elements emitted by the
sources downstream.
|
static <T> Flux<T> |
Flux.concatDelayError(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources)
Concatenate all sources emitted as an onNext signal from a parent
Publisher ,
forwarding elements emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concatDelayError(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources,
boolean delayUntilEnd,
int prefetch)
Concatenate all sources emitted as an onNext signal from a parent
Publisher ,
forwarding elements emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concatDelayError(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources,
int prefetch)
Concatenate all sources emitted as an onNext signal from a parent
Publisher ,
forwarding elements emitted by the sources downstream. |
static <T> Flux<T> |
Flux.concatDelayError(org.reactivestreams.Publisher<? extends T>... sources)
Concatenate all sources provided as a vararg, forwarding elements emitted by the
sources downstream.
|
<V> Flux<V> |
Flux.concatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper)
|
<V> Flux<V> |
Flux.concatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
int prefetch)
|
<V> Flux<V> |
Flux.concatMapDelayError(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper)
|
<V> Flux<V> |
Flux.concatMapDelayError(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
boolean delayUntilEnd,
int prefetch)
|
<V> Flux<V> |
Flux.concatMapDelayError(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
int prefetch)
|
<R> Flux<R> |
Flux.concatMapIterable(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends R>> mapper)
|
<R> Flux<R> |
Flux.concatMapIterable(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends R>> mapper,
int prefetch)
|
Flux<T> |
Mono.concatWith(org.reactivestreams.Publisher<? extends T> other)
将多个源连接起来返回一个 Flux
Concatenate emissions of this
Mono with the provided Publisher
(no interleave). |
Flux<T> |
Flux.concatWith(org.reactivestreams.Publisher<? extends T> other)
Concatenate emissions of this
Flux with the provided Publisher (no interleave). |
Flux<T> |
Flux.concatWithValues(T... values)
Concatenates the values to the end of the
Flux
|
Flux<T> |
Flux.contextCapture()
If context-propagation library
is on the classpath, this is a convenience shortcut to capture thread local values during the
subscription phase and put them in the
Context that is visible upstream of this operator. |
Flux<T> |
Flux.contextWrite(ContextView contextToAppend)
Enrich the
Context visible from downstream for the benefit of upstream
operators, by making all values from the provided ContextView visible on top
of pairs from downstream. |
Flux<T> |
Flux.contextWrite(java.util.function.Function<Context,Context> contextModifier)
|
static <T> Flux<T> |
Hooks.convertToFluxBypassingHooks(org.reactivestreams.Publisher<T> publisher)
|
static <T> Flux<T> |
Flux.create(java.util.function.Consumer<? super FluxSink<T>> emitter)
|
static <T> Flux<T> |
Flux.create(java.util.function.Consumer<? super FluxSink<T>> emitter,
FluxSink.OverflowStrategy backpressure)
|
Flux<T> |
Flux.defaultIfEmpty(T defaultV)
Provide a default unique value if this sequence is completed without any data
|
static <T> Flux<T> |
Flux.defer(java.util.function.Supplier<? extends org.reactivestreams.Publisher<T>> supplier)
Lazily supply a
Publisher every time a Subscription is made on the
resulting Flux , so the actual source instantiation is deferred until each
subscribe and the Supplier can create a subscriber-specific instance. |
static <T> Flux<T> |
Flux.deferContextual(java.util.function.Function<ContextView,? extends org.reactivestreams.Publisher<T>> contextualPublisherFactory)
Lazily supply a
Publisher every time a Subscription is made on the
resulting Flux , so the actual source instantiation is deferred until each
subscribe and the Function can create a subscriber-specific instance. |
Flux<T> |
Flux.delayElements(java.time.Duration delay)
|
Flux<T> |
Flux.delayElements(java.time.Duration delay,
Scheduler timer)
|
Flux<T> |
Flux.delaySequence(java.time.Duration delay)
Shift this
Flux forward in time by a given Duration . |
Flux<T> |
Flux.delaySequence(java.time.Duration delay,
Scheduler timer)
Shift this
Flux forward in time by a given Duration . |
Flux<T> |
Flux.delaySubscription(java.time.Duration delay)
Delay the
subscription to this Flux source until the given
period elapses. |
Flux<T> |
Flux.delaySubscription(java.time.Duration delay,
Scheduler timer)
Delay the
subscription to this Flux source until the given
period elapses, as measured on the user-provided Scheduler . |
<U> Flux<T> |
Flux.delaySubscription(org.reactivestreams.Publisher<U> subscriptionDelay)
|
Flux<T> |
Flux.delayUntil(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<?>> triggerProvider)
Subscribe to this
Flux and generate a Publisher from each of this
Flux elements, each acting as a trigger for relaying said element. |
<X> Flux<X> |
Flux.dematerialize()
An operator working only if this
Flux emits onNext, onError or onComplete Signal
instances, transforming these materialized signals into
real signals on the Subscriber . |
Flux<T> |
Flux.distinct()
For each
Subscriber , track elements from this Flux that have been
seen and filter out duplicates. |
<V> Flux<T> |
Flux.distinct(java.util.function.Function<? super T,? extends V> keySelector)
For each
Subscriber , track elements from this Flux that have been
seen and filter out duplicates, as compared by a key extracted through the user
provided Function . |
<V,C extends java.util.Collection<? super V>> |
Flux.distinct(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.Supplier<C> distinctCollectionSupplier)
For each
Subscriber , track elements from this Flux that have been
seen and filter out duplicates, as compared by a key extracted through the user
provided Function and by the add method
of the Collection supplied (typically a Set ). |
<V,C> Flux<T> |
Flux.distinct(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.Supplier<C> distinctStoreSupplier,
java.util.function.BiPredicate<C,V> distinctPredicate,
java.util.function.Consumer<C> cleanup)
For each
Subscriber , track elements from this Flux that have been
seen and filter out duplicates, as compared by applying a BiPredicate on
an arbitrary user-supplied <C> store and a key extracted through the user
provided Function . |
Flux<T> |
Flux.distinctUntilChanged()
Filter out subsequent repetitions of an element (that is, if they arrive right after
one another).
|
<V> Flux<T> |
Flux.distinctUntilChanged(java.util.function.Function<? super T,? extends V> keySelector)
Filter out subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function
using equality. |
<V> Flux<T> |
Flux.distinctUntilChanged(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.BiPredicate<? super V,? super V> keyComparator)
Filter out subsequent repetitions of an element (that is, if they arrive right
after one another), as compared by a key extracted through the user provided
Function and then comparing keys with the supplied BiPredicate . |
Flux<T> |
Flux.doAfterTerminate(java.lang.Runnable afterTerminate)
Add behavior (side-effect) triggered after the
Flux terminates, either by completing downstream successfully or with an error. |
Flux<T> |
Flux.doFinally(java.util.function.Consumer<SignalType> onFinally)
Add behavior (side-effect) triggered after the
Flux terminates for any reason,
including cancellation. |
Flux<T> |
Flux.doFirst(java.lang.Runnable onFirst)
Add behavior (side-effect) triggered before the
Flux is
subscribed to, which should be the first event after assembly time. |
Flux<T> |
Flux.doOnCancel(java.lang.Runnable onCancel)
Add behavior (side-effect) triggered when the
Flux is cancelled. |
Flux<T> |
Flux.doOnComplete(java.lang.Runnable onComplete)
Add behavior (side-effect) triggered when the
Flux completes successfully. |
<R> Flux<T> |
Flux.doOnDiscard(java.lang.Class<R> type,
java.util.function.Consumer<? super R> discardHook)
Potentially modify the behavior of the whole chain of operators upstream of this one to
conditionally clean up elements that get discarded by these operators.
|
Flux<T> |
Flux.doOnEach(java.util.function.Consumer<? super Signal<T>> signalConsumer)
Add behavior (side-effects) triggered when the
Flux emits an item, fails with an error
or completes successfully. |
<E extends java.lang.Throwable> |
Flux.doOnError(java.lang.Class<E> exceptionType,
java.util.function.Consumer<? super E> onError)
Add behavior (side-effect) triggered when the
Flux completes with an error matching the given exception type. |
Flux<T> |
Flux.doOnError(java.util.function.Consumer<? super java.lang.Throwable> onError)
Add behavior (side-effect) triggered when the
Flux completes with an error. |
Flux<T> |
Flux.doOnError(java.util.function.Predicate<? super java.lang.Throwable> predicate,
java.util.function.Consumer<? super java.lang.Throwable> onError)
Add behavior (side-effect) triggered when the
Flux completes with an error matching the given exception. |
Flux<T> |
Flux.doOnNext(java.util.function.Consumer<? super T> onNext)
Add behavior (side-effect) triggered when the
Flux emits an item. |
Flux<T> |
Flux.doOnRequest(java.util.function.LongConsumer consumer)
Add behavior (side-effect) triggering a
LongConsumer when this Flux
receives any request. |
Flux<T> |
Flux.doOnSubscribe(java.util.function.Consumer<? super org.reactivestreams.Subscription> onSubscribe)
Add behavior (side-effect) triggered when the
Flux is being subscribed,
that is to say when a Subscription has been produced by the Publisher
and is being passed to the Subscriber.onSubscribe(Subscription) . |
Flux<T> |
Flux.doOnTerminate(java.lang.Runnable onTerminate)
Add behavior (side-effect) triggered when the
Flux terminates, either by
completing successfully or failing with an error. |
Flux<Tuple2<java.lang.Long,T>> |
Flux.elapsed()
Map this
Flux into Tuple2<Long, T>
of timemillis and source data. |
Flux<Tuple2<java.lang.Long,T>> |
Flux.elapsed(Scheduler scheduler)
Map this
Flux into Tuple2<Long, T>
of timemillis and source data. |
static <T> Flux<T> |
Flux.empty()
Create a
Flux that completes without emitting any item. |
static <T> Flux<T> |
Flux.error(java.util.function.Supplier<? extends java.lang.Throwable> errorSupplier)
Create a
Flux that terminates with an error immediately after being
subscribed to. |
static <T> Flux<T> |
Flux.error(java.lang.Throwable error)
Create a
Flux that terminates with the specified error immediately after
being subscribed to. |
static <O> Flux<O> |
Flux.error(java.lang.Throwable throwable,
boolean whenRequested)
Create a
Flux that terminates with the specified error, either immediately
after being subscribed to or after being first requested. |
Flux<T> |
Mono.expand(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander)
递归地将元素展开到一个图中,并使用 宽度优先算法 遍历策略发出所有结果元素
Recursively expand elements into a graph and emit all the resulting element using
a breadth-first traversal strategy.
|
Flux<T> |
Flux.expand(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander)
Recursively expand elements into a graph and emit all the resulting element using
a breadth-first traversal strategy.
|
Flux<T> |
Mono.expand(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander,
int capacityHint)
Recursively expand elements into a graph and emit all the resulting element using
a breadth-first traversal strategy.
|
Flux<T> |
Flux.expand(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander,
int capacityHint)
Recursively expand elements into a graph and emit all the resulting element using
a breadth-first traversal strategy.
|
Flux<T> |
Mono.expandDeep(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander)
Recursively expand elements into a graph and emit all the resulting element,
in a depth-first traversal order.
|
Flux<T> |
Flux.expandDeep(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander)
Recursively expand elements into a graph and emit all the resulting element,
in a depth-first traversal order.
|
Flux<T> |
Mono.expandDeep(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander,
int capacityHint)
Recursively expand elements into a graph and emit all the resulting element,
in a depth-first traversal order.
|
Flux<T> |
Flux.expandDeep(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends T>> expander,
int capacityHint)
Recursively expand elements into a graph and emit all the resulting element,
in a depth-first traversal order.
|
Flux<T> |
Flux.filter(java.util.function.Predicate<? super T> p)
Evaluate each source value against the given
Predicate . |
Flux<T> |
Flux.filterWhen(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<java.lang.Boolean>> asyncPredicate)
Test each value emitted by this
Flux asynchronously using a generated
Publisher<Boolean> test. |
Flux<T> |
Flux.filterWhen(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<java.lang.Boolean>> asyncPredicate,
int bufferSize)
Test each value emitted by this
Flux asynchronously using a generated
Publisher<Boolean> test. |
static <I> Flux<I> |
Flux.first(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources)
已过时。
use
firstWithSignal(Iterable) . To be removed in reactor 3.5. |
static <I> Flux<I> |
Flux.first(org.reactivestreams.Publisher<? extends I>... sources)
已过时。
use
firstWithSignal(Publisher[]) . To be removed in reactor 3.5. |
static <I> Flux<I> |
Flux.firstWithSignal(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources)
Pick the first
Publisher to emit any signal (onNext/onError/onComplete) and
replay all signals from that Publisher , effectively behaving like the
fastest of these competing sources. |
static <I> Flux<I> |
Flux.firstWithSignal(org.reactivestreams.Publisher<? extends I>... sources)
Pick the first
Publisher to emit any signal (onNext/onError/onComplete) and
replay all signals from that Publisher , effectively behaving like the
fastest of these competing sources. |
static <I> Flux<I> |
Flux.firstWithValue(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources)
Pick the first
Publisher to emit any value and replay all values
from that Publisher , effectively behaving like the source that first
emits an onNext . |
static <I> Flux<I> |
Flux.firstWithValue(org.reactivestreams.Publisher<? extends I> first,
org.reactivestreams.Publisher<? extends I>... others)
Pick the first
Publisher to emit any value and replay all values
from that Publisher , effectively behaving like the source that first
emits an onNext . |
<R> Flux<R> |
Flux.flatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper)
|
<R> Flux<R> |
Flux.flatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapperOnNext,
java.util.function.Function<? super java.lang.Throwable,? extends org.reactivestreams.Publisher<? extends R>> mapperOnError,
java.util.function.Supplier<? extends org.reactivestreams.Publisher<? extends R>> mapperOnComplete)
|
<V> Flux<V> |
Flux.flatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
int concurrency)
|
<V> Flux<V> |
Flux.flatMap(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
int concurrency,
int prefetch)
|
<V> Flux<V> |
Flux.flatMapDelayError(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends V>> mapper,
int concurrency,
int prefetch)
|
<R> Flux<R> |
Mono.flatMapIterable(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends R>> mapper)
|
<R> Flux<R> |
Flux.flatMapIterable(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends R>> mapper)
|
<R> Flux<R> |
Flux.flatMapIterable(java.util.function.Function<? super T,? extends java.lang.Iterable<? extends R>> mapper,
int prefetch)
|
<R> Flux<R> |
Mono.flatMapMany(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper)
|
<R> Flux<R> |
Mono.flatMapMany(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapperOnNext,
java.util.function.Function<? super java.lang.Throwable,? extends org.reactivestreams.Publisher<? extends R>> mapperOnError,
java.util.function.Supplier<? extends org.reactivestreams.Publisher<? extends R>> mapperOnComplete)
|
<R> Flux<R> |
Flux.flatMapSequential(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper)
|
<R> Flux<R> |
Flux.flatMapSequential(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper,
int maxConcurrency)
|
<R> Flux<R> |
Flux.flatMapSequential(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper,
int maxConcurrency,
int prefetch)
|
<R> Flux<R> |
Flux.flatMapSequentialDelayError(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<? extends R>> mapper,
int maxConcurrency,
int prefetch)
|
Flux<T> |
Mono.flux()
|
static <T> Flux<T> |
Flux.from(org.reactivestreams.Publisher<? extends T> source)
Decorate the specified
Publisher with the Flux API. |
static <T> Flux<T> |
Flux.fromArray(T[] array)
Create a
Flux that emits the items contained in the provided array. |
static <T> Flux<T> |
Flux.fromIterable(java.lang.Iterable<? extends T> it)
Create a
Flux that emits the items contained in the provided Iterable . |
static <T> Flux<T> |
Flux.fromStream(java.util.stream.Stream<? extends T> s)
Create a
Flux that emits the items contained in the provided Stream . |
static <T> Flux<T> |
Flux.fromStream(java.util.function.Supplier<java.util.stream.Stream<? extends T>> streamSupplier)
Create a
Flux that emits the items contained in a Stream created by
the provided Supplier for each subscription. |
static <T,S> Flux<T> |
Flux.generate(java.util.concurrent.Callable<S> stateSupplier,
java.util.function.BiFunction<S,SynchronousSink<T>,S> generator)
Programmatically create a
Flux by generating signals one-by-one via a
consumer callback and some state. |
static <T,S> Flux<T> |
Flux.generate(java.util.concurrent.Callable<S> stateSupplier,
java.util.function.BiFunction<S,SynchronousSink<T>,S> generator,
java.util.function.Consumer<? super S> stateConsumer)
Programmatically create a
Flux by generating signals one-by-one via a
consumer callback and some state, with a final cleanup callback. |
static <T> Flux<T> |
Flux.generate(java.util.function.Consumer<SynchronousSink<T>> generator)
Programmatically create a
Flux by generating signals one-by-one via a
consumer callback. |
<K> Flux<GroupedFlux<K,T>> |
Flux.groupBy(java.util.function.Function<? super T,? extends K> keyMapper)
Divide this sequence into dynamically created
Flux (or groups) for each
unique key, as produced by the provided keyMapper Function . |
<K,V> Flux<GroupedFlux<K,V>> |
Flux.groupBy(java.util.function.Function<? super T,? extends K> keyMapper,
java.util.function.Function<? super T,? extends V> valueMapper)
Divide this sequence into dynamically created
Flux (or groups) for each
unique key, as produced by the provided keyMapper Function . |
<K,V> Flux<GroupedFlux<K,V>> |
Flux.groupBy(java.util.function.Function<? super T,? extends K> keyMapper,
java.util.function.Function<? super T,? extends V> valueMapper,
int prefetch)
Divide this sequence into dynamically created
Flux (or groups) for each
unique key, as produced by the provided keyMapper Function . |
<K> Flux<GroupedFlux<K,T>> |
Flux.groupBy(java.util.function.Function<? super T,? extends K> keyMapper,
int prefetch)
Divide this sequence into dynamically created
Flux (or groups) for each
unique key, as produced by the provided keyMapper Function . |
<TRight,TLeftEnd,TRightEnd,R> |
Flux.groupJoin(org.reactivestreams.Publisher<? extends TRight> other,
java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<TLeftEnd>> leftEnd,
java.util.function.Function<? super TRight,? extends org.reactivestreams.Publisher<TRightEnd>> rightEnd,
java.util.function.BiFunction<? super T,? super Flux<TRight>,? extends R> resultSelector)
Map values from two Publishers into time windows and emit combination of values
in case their windows overlap.
|
Flux<GroupedFlux<java.lang.Integer,T>> |
ParallelFlux.groups()
Exposes the 'rails' as individual GroupedFlux instances, keyed by the rail
index (zero based).
|
<R> Flux<R> |
Flux.handle(java.util.function.BiConsumer<? super T,SynchronousSink<R>> handler)
Handle the items emitted by this
Flux by calling a biconsumer with the
output sink for each onNext. |
Flux<T> |
Flux.hide()
Hides the identities of this
Flux instance. |
Flux<Tuple2<java.lang.Long,T>> |
Flux.index()
Keep information about the order in which source values were received by
indexing them with a 0-based incrementing long, returning a
Flux
of Tuple2<(index, value)> . |
<I> Flux<I> |
Flux.index(java.util.function.BiFunction<? super java.lang.Long,? super T,? extends I> indexMapper)
Keep information about the order in which source values were received by
indexing them internally with a 0-based incrementing long then combining this
information with the source value into a
I using the provided BiFunction ,
returning a Flux<I> . |
static Flux<java.lang.Long> |
Flux.interval(java.time.Duration period)
Create a
Flux that emits long values starting with 0 and incrementing at
specified time intervals on the global timer. |
static Flux<java.lang.Long> |
Flux.interval(java.time.Duration delay,
java.time.Duration period)
Create a
Flux that emits long values starting with 0 and incrementing at
specified time intervals, after an initial delay, on the global timer. |
static Flux<java.lang.Long> |
Flux.interval(java.time.Duration delay,
java.time.Duration period,
Scheduler timer)
|
static Flux<java.lang.Long> |
Flux.interval(java.time.Duration period,
Scheduler timer)
|
<TRight,TLeftEnd,TRightEnd,R> |
Flux.join(org.reactivestreams.Publisher<? extends TRight> other,
java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<TLeftEnd>> leftEnd,
java.util.function.Function<? super TRight,? extends org.reactivestreams.Publisher<TRightEnd>> rightEnd,
java.util.function.BiFunction<? super T,? super TRight,? extends R> resultSelector)
Combine values from two Publishers in case their windows overlap.
|
static <T> Flux<T> |
Flux.just(T... data)
Create a
Flux that emits the provided elements and then completes. |
static <T> Flux<T> |
Flux.just(T data)
Create a new
Flux that will only emit a single element then onComplete. |
Flux<T> |
Flux.limitRate(int prefetchRate)
Ensure that backpressure signals from downstream subscribers are split into batches
capped at the provided
prefetchRate when propagated upstream, effectively
rate limiting the upstream Publisher . |
Flux<T> |
Flux.limitRate(int highTide,
int lowTide)
Ensure that backpressure signals from downstream subscribers are split into batches
capped at the provided
highTide first, then replenishing at the provided
lowTide , effectively rate limiting the upstream Publisher . |
Flux<T> |
Flux.limitRequest(long n)
已过时。
replace with
take(n, true) in 3.4.x, then take(long) in 3.5.0.
To be removed in 3.6.0 at the earliest. See https://github.com/reactor/reactor-core/issues/2339 |
Flux<T> |
Flux.log()
Observe all Reactive Streams signals and trace them using
Logger support. |
Flux<T> |
Flux.log(Logger logger)
Observe Reactive Streams signals matching the passed filter
options and
trace them using a specific user-provided Logger , at Level.INFO level. |
Flux<T> |
Flux.log(Logger logger,
java.util.logging.Level level,
boolean showOperatorLine,
SignalType... options)
Observe Reactive Streams signals matching the passed filter
options and
trace them using a specific user-provided Logger , at the given Level . |
Flux<T> |
Flux.log(java.lang.String category)
Observe all Reactive Streams signals and trace them using
Logger support. |
Flux<T> |
Flux.log(java.lang.String category,
java.util.logging.Level level,
boolean showOperatorLine,
SignalType... options)
Observe Reactive Streams signals matching the passed filter
options and
trace them using Logger support. |
Flux<T> |
Flux.log(java.lang.String category,
java.util.logging.Level level,
SignalType... options)
Observe Reactive Streams signals matching the passed filter
options and
trace them using Logger support. |
<V> Flux<V> |
Flux.map(java.util.function.Function<? super T,? extends V> mapper)
Transform the items emitted by this
Flux by applying a synchronous function
to each item. |
<V> Flux<V> |
Flux.mapNotNull(java.util.function.Function<? super T,? extends V> mapper)
Transform the items emitted by this
Flux by applying a synchronous function
to each item, which may produce null values. |
Flux<Signal<T>> |
Flux.materialize()
Transform incoming onNext, onError and onComplete signals into
Signal instances,
materializing these signals. |
static <I> Flux<I> |
Flux.merge(int prefetch,
org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences contained in an array / vararg
into an interleaved merged sequence. |
static <I> Flux<I> |
Flux.merge(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources)
Merge data from
Publisher sequences contained in an Iterable
into an interleaved merged sequence. |
static <I> Flux<I> |
Flux.merge(org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences contained in an array / vararg
into an interleaved merged sequence. |
static <T> Flux<T> |
Flux.merge(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> source)
Merge data from
Publisher sequences emitted by the passed Publisher
into an interleaved merged sequence. |
static <T> Flux<T> |
Flux.merge(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> source,
int concurrency)
Merge data from
Publisher sequences emitted by the passed Publisher
into an interleaved merged sequence. |
static <T> Flux<T> |
Flux.merge(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> source,
int concurrency,
int prefetch)
Merge data from
Publisher sequences emitted by the passed Publisher
into an interleaved merged sequence. |
static <T> Flux<T> |
Flux.mergeComparing(java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ). |
static <T> Flux<T> |
Flux.mergeComparing(int prefetch,
java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ). |
static <I extends java.lang.Comparable<? super I>> |
Flux.mergeComparing(org.reactivestreams.Publisher<? extends I>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by their natural order). |
static <T> Flux<T> |
Flux.mergeComparingDelayError(int prefetch,
java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ). |
Flux<T> |
Flux.mergeComparingWith(org.reactivestreams.Publisher<? extends T> other,
java.util.Comparator<? super T> otherComparator)
Merge data from this
Flux and a Publisher into a reordered merge
sequence, by picking the smallest value from each sequence as defined by a provided
Comparator . |
static <I> Flux<I> |
Flux.mergeDelayError(int prefetch,
org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences contained in an array / vararg
into an interleaved merged sequence. |
static <T> Flux<T> |
Flux.mergeOrdered(java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
已过时。
Use
mergeComparingDelayError(int, Comparator, Publisher[]) instead
(as mergeComparing(Publisher[]) don't have this operator's delayError behavior).
To be removed in 3.6.0 at the earliest. |
static <T> Flux<T> |
Flux.mergeOrdered(int prefetch,
java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
已过时。
Use
mergeComparingDelayError(int, Comparator, Publisher[]) instead
(as mergeComparing(Publisher[]) don't have this operator's delayError behavior).
To be removed in 3.6.0 at the earliest. |
static <I extends java.lang.Comparable<? super I>> |
Flux.mergeOrdered(org.reactivestreams.Publisher<? extends I>... sources)
已过时。
Use
mergeComparingDelayError(int, Comparator, Publisher[]) instead
(as mergeComparing(Publisher[]) don't have this operator's delayError behavior).
To be removed in 3.6.0 at the earliest. |
Flux<T> |
Flux.mergeOrderedWith(org.reactivestreams.Publisher<? extends T> other,
java.util.Comparator<? super T> otherComparator)
已过时。
Use
mergeComparingWith(Publisher, Comparator) instead
(with the caveat that it defaults to NOT delaying errors, unlike this operator).
To be removed in 3.6.0 at the earliest. |
static <T> Flux<T> |
Flux.mergePriority(java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ) as they arrive. |
static <T> Flux<T> |
Flux.mergePriority(int prefetch,
java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ) as they arrive. |
static <I extends java.lang.Comparable<? super I>> |
Flux.mergePriority(org.reactivestreams.Publisher<? extends I>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by their natural order) as they arrive. |
static <T> Flux<T> |
Flux.mergePriorityDelayError(int prefetch,
java.util.Comparator<? super T> comparator,
org.reactivestreams.Publisher<? extends T>... sources)
Merge data from provided
Publisher sequences into an ordered merged sequence,
by picking the smallest values from each source (as defined by the provided
Comparator ) as they arrive. |
static <I> Flux<I> |
Flux.mergeSequential(int prefetch,
org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences provided in an array/vararg
into an ordered merged sequence. |
static <I> Flux<I> |
Flux.mergeSequential(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources)
Merge data from
Publisher sequences provided in an Iterable
into an ordered merged sequence. |
static <I> Flux<I> |
Flux.mergeSequential(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources,
int maxConcurrency,
int prefetch)
Merge data from
Publisher sequences provided in an Iterable
into an ordered merged sequence. |
static <I> Flux<I> |
Flux.mergeSequential(org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences provided in an array/vararg
into an ordered merged sequence. |
static <T> Flux<T> |
Flux.mergeSequential(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources)
Merge data from
Publisher sequences emitted by the passed Publisher
into an ordered merged sequence. |
static <T> Flux<T> |
Flux.mergeSequential(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources,
int maxConcurrency,
int prefetch)
Merge data from
Publisher sequences emitted by the passed Publisher
into an ordered merged sequence. |
static <I> Flux<I> |
Flux.mergeSequentialDelayError(int prefetch,
org.reactivestreams.Publisher<? extends I>... sources)
Merge data from
Publisher sequences provided in an array/vararg
into an ordered merged sequence. |
static <I> Flux<I> |
Flux.mergeSequentialDelayError(java.lang.Iterable<? extends org.reactivestreams.Publisher<? extends I>> sources,
int maxConcurrency,
int prefetch)
Merge data from
Publisher sequences provided in an Iterable
into an ordered merged sequence. |
static <T> Flux<T> |
Flux.mergeSequentialDelayError(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> sources,
int maxConcurrency,
int prefetch)
Merge data from
Publisher sequences emitted by the passed Publisher
into an ordered merged sequence. |
Flux<T> |
Mono.mergeWith(org.reactivestreams.Publisher<? extends T> other)
Merge emissions of this
Mono with the provided Publisher . |
Flux<T> |
Flux.mergeWith(org.reactivestreams.Publisher<? extends T> other)
Merge data from this
Flux and a Publisher into an interleaved merged
sequence. |
Flux<T> |
Flux.metrics()
已过时。
Prefer using the
tap(SignalListenerFactory) with the SignalListenerFactory provided by
the new reactor-core-micrometer module. To be removed in 3.6.0 at the earliest. |
Flux<T> |
Flux.name(java.lang.String name)
Give a name to this sequence, which can be retrieved using
Scannable.name()
as long as this is the first reachable Scannable.parents() . |
static <T> Flux<T> |
Flux.never()
Create a
Flux that will never signal any data, error or completion signal. |
<U> Flux<U> |
Flux.ofType(java.lang.Class<U> clazz)
Evaluate each accepted value against the given
Class type. |
Flux<T> |
Flux.onBackpressureBuffer()
Request an unbounded demand and push to the returned
Flux , or park the
observed elements if not enough demand is requested downstream. |
Flux<T> |
Flux.onBackpressureBuffer(java.time.Duration ttl,
int maxSize,
java.util.function.Consumer<? super T> onBufferEviction)
Request an unbounded demand and push to the returned
Flux , or park the observed
elements if not enough demand is requested downstream, within a maxSize
limit and for a maximum Duration of ttl (as measured on the
parallel Scheduler ). |
Flux<T> |
Flux.onBackpressureBuffer(java.time.Duration ttl,
int maxSize,
java.util.function.Consumer<? super T> onBufferEviction,
Scheduler scheduler)
|
Flux<T> |
Flux.onBackpressureBuffer(int maxSize)
Request an unbounded demand and push to the returned
Flux , or park up to
maxSize elements when not enough demand is requested downstream. |
Flux<T> |
Flux.onBackpressureBuffer(int maxSize,
BufferOverflowStrategy bufferOverflowStrategy)
Request an unbounded demand and push to the returned
Flux , or park the observed
elements if not enough demand is requested downstream, within a maxSize
limit. |
Flux<T> |
Flux.onBackpressureBuffer(int maxSize,
java.util.function.Consumer<? super T> onOverflow)
Request an unbounded demand and push to the returned
Flux , or park up to
maxSize elements when not enough demand is requested downstream. |
Flux<T> |
Flux.onBackpressureBuffer(int maxSize,
java.util.function.Consumer<? super T> onBufferOverflow,
BufferOverflowStrategy bufferOverflowStrategy)
Request an unbounded demand and push to the returned
Flux , or park the observed
elements if not enough demand is requested downstream, within a maxSize
limit. |
Flux<T> |
Flux.onBackpressureDrop()
Request an unbounded demand and push to the returned
Flux , or drop
the observed elements if not enough demand is requested downstream. |
Flux<T> |
Flux.onBackpressureDrop(java.util.function.Consumer<? super T> onDropped)
Request an unbounded demand and push to the returned
Flux , or drop and
notify dropping Consumer with the observed elements if not enough demand
is requested downstream. |
Flux<T> |
Flux.onBackpressureError()
Request an unbounded demand and push to the returned
Flux , or emit onError
fom Exceptions.failWithOverflow() if not enough demand is requested
downstream. |
Flux<T> |
Flux.onBackpressureLatest()
Request an unbounded demand and push to the returned
Flux , or only keep
the most recent observed item if not enough demand is requested downstream. |
Flux<T> |
Flux.onErrorComplete()
Simply complete the sequence by replacing an
onError signal
with an onComplete signal . |
Flux<T> |
Flux.onErrorComplete(java.lang.Class<? extends java.lang.Throwable> type)
Simply complete the sequence by replacing an
onError signal
with an onComplete signal if the error matches the given
Class . |
Flux<T> |
Flux.onErrorComplete(java.util.function.Predicate<? super java.lang.Throwable> predicate)
Simply complete the sequence by replacing an
onError signal
with an onComplete signal if the error matches the given
Predicate . |
Flux<T> |
Flux.onErrorContinue(java.util.function.BiConsumer<java.lang.Throwable,java.lang.Object> errorConsumer)
Let compatible operators upstream recover from errors by dropping the
incriminating element from the sequence and continuing with subsequent elements.
|
<E extends java.lang.Throwable> |
Flux.onErrorContinue(java.lang.Class<E> type,
java.util.function.BiConsumer<java.lang.Throwable,java.lang.Object> errorConsumer)
Let compatible operators upstream recover from errors by dropping the
incriminating element from the sequence and continuing with subsequent elements.
|
<E extends java.lang.Throwable> |
Flux.onErrorContinue(java.util.function.Predicate<E> errorPredicate,
java.util.function.BiConsumer<java.lang.Throwable,java.lang.Object> errorConsumer)
Let compatible operators upstream recover from errors by dropping the
incriminating element from the sequence and continuing with subsequent elements.
|
<E extends java.lang.Throwable> |
Flux.onErrorMap(java.lang.Class<E> type,
java.util.function.Function<? super E,? extends java.lang.Throwable> mapper)
Transform an error emitted by this
Flux by synchronously applying a function
to it if the error matches the given type. |
Flux<T> |
Flux.onErrorMap(java.util.function.Function<? super java.lang.Throwable,? extends java.lang.Throwable> mapper)
Transform any error emitted by this
Flux by synchronously applying a function to it. |
Flux<T> |
Flux.onErrorMap(java.util.function.Predicate<? super java.lang.Throwable> predicate,
java.util.function.Function<? super java.lang.Throwable,? extends java.lang.Throwable> mapper)
Transform an error emitted by this
Flux by synchronously applying a function
to it if the error matches the given predicate. |
<E extends java.lang.Throwable> |
Flux.onErrorResume(java.lang.Class<E> type,
java.util.function.Function<? super E,? extends org.reactivestreams.Publisher<? extends T>> fallback)
Subscribe to a fallback publisher when an error matching the given type
occurs, using a function to choose the fallback depending on the error.
|
Flux<T> |
Flux.onErrorResume(java.util.function.Function<? super java.lang.Throwable,? extends org.reactivestreams.Publisher<? extends T>> fallback)
Subscribe to a returned fallback publisher when any error occurs, using a function to
choose the fallback depending on the error.
|
Flux<T> |
Flux.onErrorResume(java.util.function.Predicate<? super java.lang.Throwable> predicate,
java.util.function.Function<? super java.lang.Throwable,? extends org.reactivestreams.Publisher<? extends T>> fallback)
Subscribe to a fallback publisher when an error matching a given predicate
occurs.
|
<E extends java.lang.Throwable> |
Flux.onErrorReturn(java.lang.Class<E> type,
T fallbackValue)
Simply emit a captured fallback value when an error of the specified type is
observed on this
Flux . |
Flux<T> |
Flux.onErrorReturn(java.util.function.Predicate<? super java.lang.Throwable> predicate,
T fallbackValue)
Simply emit a captured fallback value when an error matching the given predicate is
observed on this
Flux . |
Flux<T> |
Flux.onErrorReturn(T fallbackValue)
Simply emit a captured fallback value when any error is observed on this
Flux . |
Flux<T> |
Flux.onErrorStop()
If an
onErrorContinue(BiConsumer) variant has been used downstream, reverts
to the default 'STOP' mode where errors are terminal events upstream. |
Flux<T> |
Flux.onTerminateDetach()
Detaches both the child
Subscriber and the Subscription on
termination or cancellation. |
Flux<T> |
Flux.or(org.reactivestreams.Publisher<? extends T> other)
Pick the first
Publisher between this Flux and another publisher
to emit any signal (onNext/onError/onComplete) and replay all signals from that
Publisher , effectively behaving like the fastest of these competing sources. |
Flux<T> |
ParallelFlux.ordered(java.util.Comparator<? super T> comparator)
Merges the values from each 'rail', but choose which one to merge by way of a
provided
Comparator , picking the smallest of all rails. |
Flux<T> |
ParallelFlux.ordered(java.util.Comparator<? super T> comparator,
int prefetch)
Merges the values from each 'rail', but choose which one to merge by way of a
provided
Comparator , picking the smallest of all rails. |
<R> Flux<R> |
Flux.publish(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<? extends R>> transform)
Shares a sequence for the duration of a function that may transform it and
consume it as many times as necessary without causing multiple subscriptions
to the upstream.
|
<R> Flux<R> |
Flux.publish(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<? extends R>> transform,
int prefetch)
Shares a sequence for the duration of a function that may transform it and
consume it as many times as necessary without causing multiple subscriptions
to the upstream.
|
Flux<T> |
Flux.publishOn(Scheduler scheduler)
|
Flux<T> |
Flux.publishOn(Scheduler scheduler,
boolean delayError,
int prefetch)
Run onNext, onComplete and onError on a supplied
Scheduler
Scheduler.Worker . |
Flux<T> |
Flux.publishOn(Scheduler scheduler,
int prefetch)
Run onNext, onComplete and onError on a supplied
Scheduler
Scheduler.Worker . |
static <T> Flux<T> |
Flux.push(java.util.function.Consumer<? super FluxSink<T>> emitter)
|
static <T> Flux<T> |
Flux.push(java.util.function.Consumer<? super FluxSink<T>> emitter,
FluxSink.OverflowStrategy backpressure)
|
static Flux<java.lang.Integer> |
Flux.range(int start,
int count)
|
Flux<T> |
ConnectableFlux.refCount()
Connects to the upstream source when the first
Subscriber subscribes and disconnects
when all Subscribers cancelled or the upstream source completed. |
Flux<T> |
ConnectableFlux.refCount(int minSubscribers)
Connects to the upstream source when the given number of
Subscriber subscribes and disconnects
when all Subscribers cancelled or the upstream source completed. |
Flux<T> |
ConnectableFlux.refCount(int minSubscribers,
java.time.Duration gracePeriod)
Connects to the upstream source when the given number of
Subscriber subscribes. |
Flux<T> |
ConnectableFlux.refCount(int minSubscribers,
java.time.Duration gracePeriod,
Scheduler scheduler)
Connects to the upstream source when the given number of
Subscriber subscribes. |
Flux<T> |
Mono.repeat()
在上一次订阅完成后重复无限期订阅源
Repeatedly and indefinitely subscribe to the source upon completion of the
previous subscription.
|
Flux<T> |
Flux.repeat()
Repeatedly and indefinitely subscribe to the source upon completion of the
previous subscription.
|
Flux<T> |
Mono.repeat(java.util.function.BooleanSupplier predicate)
如果
BooleanSupplier 在上一次订阅完成后返回 true,则重复订阅源
Repeatedly subscribe to the source if the predicate returns true after completion of the previous subscription. |
Flux<T> |
Flux.repeat(java.util.function.BooleanSupplier predicate)
Repeatedly subscribe to the source if the predicate returns true after completion of the previous subscription.
|
Flux<T> |
Mono.repeat(long numRepeat)
重复订阅源 numRepeat 次。
|
Flux<T> |
Flux.repeat(long numRepeat)
Repeatedly subscribe to the source
numRepeat times. |
Flux<T> |
Mono.repeat(long numRepeat,
java.util.function.BooleanSupplier predicate)
重复订阅,如果 predicate 在上一次订阅完成后返回 true,则重复订阅源,可指定重复次数
Repeatedly subscribe to the source if the predicate returns true after completion of the previous
subscription.
|
Flux<T> |
Flux.repeat(long numRepeat,
java.util.function.BooleanSupplier predicate)
Repeatedly subscribe to the source if the predicate returns true after completion of the previous
subscription.
|
Flux<T> |
Mono.repeatWhen(java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
Repeatedly subscribe to this
Mono when a companion sequence emits elements in
response to the flux completion signal. |
Flux<T> |
Flux.repeatWhen(java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
Repeatedly subscribe to this
Flux when a companion sequence emits elements in
response to the flux completion signal. |
Flux<T> |
Flux.retry()
Re-subscribes to this
Flux sequence if it signals any error, indefinitely. |
Flux<T> |
Flux.retry(long numRetries)
Re-subscribes to this
Flux sequence if it signals any error, for a fixed
number of times. |
Flux<T> |
Flux.retryWhen(Retry retrySpec)
Retries this
Flux in response to signals emitted by a companion Publisher . |
Flux<T> |
Flux.sample(java.time.Duration timespan)
|
<U> Flux<T> |
Flux.sample(org.reactivestreams.Publisher<U> sampler)
|
Flux<T> |
Flux.sampleFirst(java.time.Duration timespan)
Repeatedly take a value from this
Flux then skip the values that follow
within a given duration. |
<U> Flux<T> |
Flux.sampleFirst(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<U>> samplerFactory)
Repeatedly take a value from this
Flux then skip the values that follow
before the next signal from a companion sampler Publisher . |
<U> Flux<T> |
Flux.sampleTimeout(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<U>> throttlerFactory)
Emit the latest value from this
Flux only if there were no new values emitted
during the window defined by a companion Publisher derived from that particular
value. |
<U> Flux<T> |
Flux.sampleTimeout(java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<U>> throttlerFactory,
int maxConcurrency)
Emit the latest value from this
Flux only if there were no new values emitted
during the window defined by a companion Publisher derived from that particular
value. |
<A> Flux<A> |
Flux.scan(A initial,
java.util.function.BiFunction<A,? super T,A> accumulator)
Reduce this
Flux values with an accumulator BiFunction and
also emit the intermediate results of this function. |
Flux<T> |
Flux.scan(java.util.function.BiFunction<T,T,T> accumulator)
Reduce this
Flux values with an accumulator BiFunction and
also emit the intermediate results of this function. |
<A> Flux<A> |
Flux.scanWith(java.util.function.Supplier<A> initial,
java.util.function.BiFunction<A,? super T,A> accumulator)
Reduce this
Flux values with the help of an accumulator BiFunction
and also emits the intermediate results. |
Flux<T> |
ParallelFlux.sequential()
Merges the values from each 'rail' in a round-robin or same-order fashion and
exposes it as a regular Publisher sequence, running with a default prefetch value
for the rails.
|
Flux<T> |
ParallelFlux.sequential(int prefetch)
Merges the values from each 'rail' in a round-robin or same-order fashion and
exposes it as a regular Publisher sequence, running with a give prefetch value for
the rails.
|
Flux<T> |
Flux.share()
|
Flux<T> |
Flux.skip(java.time.Duration timespan)
Skip elements from this
Flux emitted within the specified initial duration. |
Flux<T> |
Flux.skip(java.time.Duration timespan,
Scheduler timer)
|
Flux<T> |
Flux.skip(long skipped)
Skip the specified number of elements from the beginning of this
Flux then
emit the remaining elements. |
Flux<T> |
Flux.skipLast(int n)
Skip a specified number of elements at the end of this
Flux sequence. |
Flux<T> |
Flux.skipUntil(java.util.function.Predicate<? super T> untilPredicate)
Skips values from this
Flux until a Predicate returns true for the
value. |
Flux<T> |
Flux.skipUntilOther(org.reactivestreams.Publisher<?> other)
Skip values from this
Flux until a specified Publisher signals
an onNext or onComplete. |
Flux<T> |
Flux.skipWhile(java.util.function.Predicate<? super T> skipPredicate)
Skips values from this
Flux while a Predicate returns true for the value. |
Flux<T> |
Flux.sort()
Sort elements from this
Flux by collecting and sorting them in the background
then emitting the sorted sequence once this sequence completes. |
Flux<T> |
Flux.sort(java.util.Comparator<? super T> sortFunction)
Sort elements from this
Flux using a Comparator function, by
collecting and sorting elements in the background then emitting the sorted sequence
once this sequence completes. |
Flux<T> |
ParallelFlux.sorted(java.util.Comparator<? super T> comparator)
Sorts the 'rails' of this
ParallelFlux and returns a Publisher that
sequentially picks the smallest next value from the rails. |
Flux<T> |
ParallelFlux.sorted(java.util.Comparator<? super T> comparator,
int capacityHint)
Sorts the 'rails' of this
ParallelFlux and returns a Publisher that
sequentially picks the smallest next value from the rails. |
Flux<T> |
Flux.startWith(java.lang.Iterable<? extends T> iterable)
Prepend the given
Iterable before this Flux sequence. |
Flux<T> |
Flux.startWith(org.reactivestreams.Publisher<? extends T> publisher)
Prepend the given
Publisher sequence to this Flux sequence. |
Flux<T> |
Flux.startWith(T... values)
Prepend the given values before this
Flux sequence. |
Flux<T> |
Flux.subscribeOn(Scheduler scheduler)
Run subscribe, onSubscribe and request on a specified
Scheduler 's Scheduler.Worker . |
Flux<T> |
Flux.subscribeOn(Scheduler scheduler,
boolean requestOnSeparateThread)
Run subscribe and onSubscribe on a specified
Scheduler 's Scheduler.Worker . |
Flux<T> |
Flux.switchIfEmpty(org.reactivestreams.Publisher<? extends T> alternate)
Switch to an alternative
Publisher if this sequence is completed without any data. |
<V> Flux<V> |
Flux.switchMap(java.util.function.Function<? super T,org.reactivestreams.Publisher<? extends V>> fn)
|
<V> Flux<V> |
Flux.switchMap(java.util.function.Function<? super T,org.reactivestreams.Publisher<? extends V>> fn,
int prefetch)
已过时。
to be removed in 3.6.0 at the earliest. In 3.5.0, you should replace
calls with prefetch=0 with calls to switchMap(fn), as the default behavior of the
single-parameter variant will then change to prefetch=0.
|
<V> Flux<V> |
Flux.switchOnFirst(java.util.function.BiFunction<Signal<? extends T>,Flux<T>,org.reactivestreams.Publisher<? extends V>> transformer)
Transform the current
Flux once it emits its first element, making a
conditional transformation possible. |
<V> Flux<V> |
Flux.switchOnFirst(java.util.function.BiFunction<Signal<? extends T>,Flux<T>,org.reactivestreams.Publisher<? extends V>> transformer,
boolean cancelSourceOnComplete)
Transform the current
Flux once it emits its first element, making a
conditional transformation possible. |
static <T> Flux<T> |
Flux.switchOnNext(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> mergedPublishers)
Creates a
Flux that mirrors the most recently emitted Publisher ,
forwarding its data until a new Publisher comes in the source. |
static <T> Flux<T> |
Flux.switchOnNext(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<? extends T>> mergedPublishers,
int prefetch)
已过时。
to be removed in 3.6.0 at the earliest. In 3.5.0, you should replace
calls with prefetch=0 with calls to switchOnNext(mergedPublishers), as the default
behavior of the single-parameter variant will then change to prefetch=0.
|
Flux<T> |
Flux.tag(java.lang.String key,
java.lang.String value)
Tag this flux with a key/value pair.
|
Flux<T> |
Flux.take(java.time.Duration timespan)
Relay values from this
Flux until the specified Duration elapses. |
Flux<T> |
Flux.take(java.time.Duration timespan,
Scheduler timer)
|
Flux<T> |
Flux.take(long n)
Take only the first N values from this
Flux , if available. |
Flux<T> |
Flux.take(long n,
boolean limitRequest)
Take only the first N values from this
Flux , if available. |
Flux<T> |
Flux.takeLast(int n)
Emit the last N values this
Flux emitted before its completion. |
Flux<T> |
Flux.takeUntil(java.util.function.Predicate<? super T> predicate)
Relay values from this
Flux until the given Predicate matches. |
Flux<T> |
Flux.takeUntilOther(org.reactivestreams.Publisher<?> other)
Relay values from this
Flux until the given Publisher emits. |
Flux<T> |
Flux.takeWhile(java.util.function.Predicate<? super T> continuePredicate)
Relay values from this
Flux while a predicate returns TRUE
for the values (checked before each value is delivered). |
Flux<T> |
Flux.tap(java.util.function.Function<ContextView,SignalListener<T>> listenerGenerator)
Tap into Reactive Streams signals emitted or received by this
Flux and notify a stateful per-Subscriber
SignalListener . |
Flux<T> |
Flux.tap(SignalListenerFactory<T,?> listenerFactory)
Tap into Reactive Streams signals emitted or received by this
Flux and notify a stateful per-Subscriber
SignalListener created by the provided SignalListenerFactory . |
Flux<T> |
Flux.tap(java.util.function.Supplier<SignalListener<T>> simpleListenerGenerator)
Tap into Reactive Streams signals emitted or received by this
Flux and notify a stateful per-Subscriber
SignalListener . |
<V> Flux<V> |
Mono.thenMany(org.reactivestreams.Publisher<V> other)
|
<V> Flux<V> |
Flux.thenMany(org.reactivestreams.Publisher<V> other)
Let this
Flux complete then play another Publisher . |
Flux<Timed<T>> |
Flux.timed()
Times
Subscriber.onNext(Object) events, encapsulated into a Timed object
that lets downstream consumer look at various time information gathered with nanosecond
resolution using the default clock (Schedulers.parallel() ):
Timed.elapsed() : the time in nanoseconds since last event, as a Duration . |
Flux<Timed<T>> |
Flux.timed(Scheduler clock)
Times
Subscriber.onNext(Object) events, encapsulated into a Timed object
that lets downstream consumer look at various time information gathered with nanosecond
resolution using the provided Scheduler as a clock:
Timed.elapsed() : the time in nanoseconds since last event, as a Duration . |
Flux<T> |
Flux.timeout(java.time.Duration timeout)
Propagate a
TimeoutException as soon as no item is emitted within the
given Duration from the previous emission (or the subscription for the first item). |
Flux<T> |
Flux.timeout(java.time.Duration timeout,
org.reactivestreams.Publisher<? extends T> fallback)
Switch to a fallback
Flux as soon as no item is emitted within the
given Duration from the previous emission (or the subscription for the first item). |
Flux<T> |
Flux.timeout(java.time.Duration timeout,
org.reactivestreams.Publisher<? extends T> fallback,
Scheduler timer)
|
Flux<T> |
Flux.timeout(java.time.Duration timeout,
Scheduler timer)
Propagate a
TimeoutException as soon as no item is emitted within the
given Duration from the previous emission (or the subscription for the first
item), as measured by the specified Scheduler . |
<U> Flux<T> |
Flux.timeout(org.reactivestreams.Publisher<U> firstTimeout)
Signal a
TimeoutException in case the first item from this Flux has
not been emitted before the given Publisher emits. |
<U,V> Flux<T> |
Flux.timeout(org.reactivestreams.Publisher<U> firstTimeout,
java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<V>> nextTimeoutFactory)
Signal a
TimeoutException in case the first item from this Flux has
not been emitted before the firstTimeout Publisher emits, and whenever
each subsequent elements is not emitted before a Publisher generated from
the latest element signals. |
<U,V> Flux<T> |
Flux.timeout(org.reactivestreams.Publisher<U> firstTimeout,
java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<V>> nextTimeoutFactory,
org.reactivestreams.Publisher<? extends T> fallback)
Switch to a fallback
Publisher in case the first item from this Flux has
not been emitted before the firstTimeout Publisher emits, and whenever
each subsequent elements is not emitted before a Publisher generated from
the latest element signals. |
Flux<Tuple2<java.lang.Long,T>> |
Flux.timestamp()
|
Flux<Tuple2<java.lang.Long,T>> |
Flux.timestamp(Scheduler scheduler)
|
<V> Flux<V> |
Flux.transform(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<V>> transformer)
|
<V> Flux<V> |
Flux.transformDeferred(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<V>> transformer)
|
<V> Flux<V> |
Flux.transformDeferredContextual(java.util.function.BiFunction<? super Flux<T>,? super ContextView,? extends org.reactivestreams.Publisher<V>> transformer)
|
static Flux<java.lang.Integer> |
FluxRetryWhenTest.transientErrorSource() |
static <T,D> Flux<T> |
Flux.using(java.util.concurrent.Callable<? extends D> resourceSupplier,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<? extends T>> sourceSupplier,
java.util.function.Consumer<? super D> resourceCleanup)
Uses a resource, generated by a supplier for each individual Subscriber, while streaming the values from a
Publisher derived from the same resource and makes sure the resource is released if the sequence terminates or
the Subscriber cancels.
|
static <T,D> Flux<T> |
Flux.using(java.util.concurrent.Callable<? extends D> resourceSupplier,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<? extends T>> sourceSupplier,
java.util.function.Consumer<? super D> resourceCleanup,
boolean eager)
Uses a resource, generated by a supplier for each individual Subscriber, while streaming the values from a
Publisher derived from the same resource and makes sure the resource is released if the sequence terminates or
the Subscriber cancels.
|
static <T,D> Flux<T> |
Flux.usingWhen(org.reactivestreams.Publisher<D> resourceSupplier,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<? extends T>> resourceClosure,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<?>> asyncCleanup)
Uses a resource, generated by a
Publisher for each individual Subscriber ,
while streaming the values from a Publisher derived from the same resource. |
static <T,D> Flux<T> |
Flux.usingWhen(org.reactivestreams.Publisher<D> resourceSupplier,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<? extends T>> resourceClosure,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<?>> asyncComplete,
java.util.function.BiFunction<? super D,? super java.lang.Throwable,? extends org.reactivestreams.Publisher<?>> asyncError,
java.util.function.Function<? super D,? extends org.reactivestreams.Publisher<?>> asyncCancel)
Uses a resource, generated by a
Publisher for each individual Subscriber ,
while streaming the values from a Publisher derived from the same resource. |
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
java.time.Duration openWindowEvery)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
java.time.Duration openWindowEvery,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.window(int maxSize)
|
Flux<Flux<T>> |
Flux.window(int maxSize,
int skip)
|
Flux<Flux<T>> |
Flux.window(org.reactivestreams.Publisher<?> boundary)
Split this
Flux sequence into continuous, non-overlapping windows
where the window boundary is signalled by another Publisher
Note that windows are a live view of part of the underlying source publisher,
and as such their lifecycle is tied to that source. |
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
boolean fairBackpressure)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer,
boolean fairBackpressure)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger,
boolean cutBefore)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger,
boolean cutBefore,
int prefetch)
|
Flux<Flux<T>> |
Flux.windowUntilChanged()
Collect subsequent repetitions of an element (that is, if they arrive right after
one another) into multiple
Flux windows. |
<V> Flux<Flux<T>> |
Flux.windowUntilChanged(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.BiPredicate<? super V,? super V> keyComparator)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function and compared using a supplied BiPredicate , into multiple
Flux windows. |
<V> Flux<Flux<T>> |
Flux.windowUntilChanged(java.util.function.Function<? super T,? super V> keySelector)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function , into multiple Flux windows. |
<U,V> Flux<Flux<T>> |
Flux.windowWhen(org.reactivestreams.Publisher<U> bucketOpening,
java.util.function.Function<? super U,? extends org.reactivestreams.Publisher<V>> closeSelector)
Split this
Flux sequence into potentially overlapping windows controlled by items of a
start Publisher and end Publisher derived from the start values. |
Flux<Flux<T>> |
Flux.windowWhile(java.util.function.Predicate<T> inclusionPredicate)
|
Flux<Flux<T>> |
Flux.windowWhile(java.util.function.Predicate<T> inclusionPredicate,
int prefetch)
|
<U,R> Flux<R> |
Flux.withLatestFrom(org.reactivestreams.Publisher<? extends U> other,
java.util.function.BiFunction<? super T,? super U,? extends R> resultSelector)
Combine the most recently emitted values from both this
Flux and another
Publisher through a BiFunction and emits the result. |
static <I,O> Flux<O> |
Flux.zip(java.util.function.Function<? super java.lang.Object[],? extends O> combinator,
int prefetch,
org.reactivestreams.Publisher<? extends I>... sources)
Zip multiple sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <I,O> Flux<O> |
Flux.zip(java.util.function.Function<? super java.lang.Object[],? extends O> combinator,
org.reactivestreams.Publisher<? extends I>... sources)
Zip multiple sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <O> Flux<O> |
Flux.zip(java.lang.Iterable<? extends org.reactivestreams.Publisher<?>> sources,
java.util.function.Function<? super java.lang.Object[],? extends O> combinator)
Zip multiple sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <O> Flux<O> |
Flux.zip(java.lang.Iterable<? extends org.reactivestreams.Publisher<?>> sources,
int prefetch,
java.util.function.Function<? super java.lang.Object[],? extends O> combinator)
Zip multiple sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <TUPLE extends Tuple2,V> |
Flux.zip(org.reactivestreams.Publisher<? extends org.reactivestreams.Publisher<?>> sources,
java.util.function.Function<? super TUPLE,? extends V> combinator)
Zip multiple sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <T1,T2> Flux<Tuple2<T1,T2>> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2)
Zip two sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple2 . |
static <T1,T2,O> Flux<O> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
java.util.function.BiFunction<? super T1,? super T2,? extends O> combinator)
Zip two sources together, that is to say wait for all the sources to emit one
element and combine these elements once into an output value (constructed by the provided
combinator).
|
static <T1,T2,T3> Flux<Tuple3<T1,T2,T3>> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3)
Zip three sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple3 . |
static <T1,T2,T3,T4> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4)
Zip four sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple4 . |
static <T1,T2,T3,T4,T5> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5)
Zip five sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple5 . |
static <T1,T2,T3,T4,T5,T6> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5,
org.reactivestreams.Publisher<? extends T6> source6)
Zip six sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple6 . |
static <T1,T2,T3,T4,T5,T6,T7> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5,
org.reactivestreams.Publisher<? extends T6> source6,
org.reactivestreams.Publisher<? extends T7> source7)
Zip seven sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple7 . |
static <T1,T2,T3,T4,T5,T6,T7,T8> |
Flux.zip(org.reactivestreams.Publisher<? extends T1> source1,
org.reactivestreams.Publisher<? extends T2> source2,
org.reactivestreams.Publisher<? extends T3> source3,
org.reactivestreams.Publisher<? extends T4> source4,
org.reactivestreams.Publisher<? extends T5> source5,
org.reactivestreams.Publisher<? extends T6> source6,
org.reactivestreams.Publisher<? extends T7> source7,
org.reactivestreams.Publisher<? extends T8> source8)
Zip eight sources together, that is to say wait for all the sources to emit one
element and combine these elements once into a
Tuple8 . |
<T2> Flux<Tuple2<T,T2>> |
Flux.zipWith(org.reactivestreams.Publisher<? extends T2> source2)
|
<T2,V> Flux<V> |
Flux.zipWith(org.reactivestreams.Publisher<? extends T2> source2,
java.util.function.BiFunction<? super T,? super T2,? extends V> combinator)
Zip this
Flux with another Publisher source, that is to say wait
for both to emit one element and combine these elements using a combinator
BiFunction
The operator will continue doing so until any of the sources completes. |
<T2> Flux<Tuple2<T,T2>> |
Flux.zipWith(org.reactivestreams.Publisher<? extends T2> source2,
int prefetch)
|
<T2,V> Flux<V> |
Flux.zipWith(org.reactivestreams.Publisher<? extends T2> source2,
int prefetch,
java.util.function.BiFunction<? super T,? super T2,? extends V> combinator)
Zip this
Flux with another Publisher source, that is to say wait
for both to emit one element and combine these elements using a combinator
BiFunction
The operator will continue doing so until any of the sources completes. |
<T2> Flux<Tuple2<T,T2>> |
Flux.zipWithIterable(java.lang.Iterable<? extends T2> iterable)
|
<T2,V> Flux<V> |
Flux.zipWithIterable(java.lang.Iterable<? extends T2> iterable,
java.util.function.BiFunction<? super T,? super T2,? extends V> zipper)
Zip elements from this
Flux with the content of an Iterable , that is
to say combine one element from each, pairwise, using the given zipper BiFunction . |
限定符和类型 | 方法和说明 |
---|---|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
java.time.Duration openWindowEvery)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
java.time.Duration openWindowEvery,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.window(java.time.Duration windowingTimespan,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.window(int maxSize)
|
Flux<Flux<T>> |
Flux.window(int maxSize,
int skip)
|
Flux<Flux<T>> |
Flux.window(org.reactivestreams.Publisher<?> boundary)
Split this
Flux sequence into continuous, non-overlapping windows
where the window boundary is signalled by another Publisher
Note that windows are a live view of part of the underlying source publisher,
and as such their lifecycle is tied to that source. |
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
boolean fairBackpressure)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer)
|
Flux<Flux<T>> |
Flux.windowTimeout(int maxSize,
java.time.Duration maxTime,
Scheduler timer,
boolean fairBackpressure)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger,
boolean cutBefore)
|
Flux<Flux<T>> |
Flux.windowUntil(java.util.function.Predicate<T> boundaryTrigger,
boolean cutBefore,
int prefetch)
|
Flux<Flux<T>> |
Flux.windowUntilChanged()
Collect subsequent repetitions of an element (that is, if they arrive right after
one another) into multiple
Flux windows. |
<V> Flux<Flux<T>> |
Flux.windowUntilChanged(java.util.function.Function<? super T,? extends V> keySelector,
java.util.function.BiPredicate<? super V,? super V> keyComparator)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function and compared using a supplied BiPredicate , into multiple
Flux windows. |
<V> Flux<Flux<T>> |
Flux.windowUntilChanged(java.util.function.Function<? super T,? super V> keySelector)
Collect subsequent repetitions of an element (that is, if they arrive right after
one another), as compared by a key extracted through the user provided
Function , into multiple Flux windows. |
<U,V> Flux<Flux<T>> |
Flux.windowWhen(org.reactivestreams.Publisher<U> bucketOpening,
java.util.function.Function<? super U,? extends org.reactivestreams.Publisher<V>> closeSelector)
Split this
Flux sequence into potentially overlapping windows controlled by items of a
start Publisher and end Publisher derived from the start values. |
Flux<Flux<T>> |
Flux.windowWhile(java.util.function.Predicate<T> inclusionPredicate)
|
Flux<Flux<T>> |
Flux.windowWhile(java.util.function.Predicate<T> inclusionPredicate,
int prefetch)
|
限定符和类型 | 方法和说明 |
---|---|
void |
FluxUsingWhenTest.apiCancel(Flux<java.lang.String> transactionToCancel) |
void |
FluxUsingWhenTest.apiCommit(Flux<java.lang.String> fullTransaction) |
void |
FluxUsingWhenTest.apiCommitFailure(Flux<java.lang.String> fullTransaction) |
void |
FluxUsingWhenTest.apiRollback(Flux<java.lang.String> transactionWithError) |
void |
FluxUsingWhenTest.apiRollbackFailure(Flux<java.lang.String> transactionWithError) |
void |
FluxUsingWhenTest.apiRollbackGeneratingNull(Flux<java.lang.String> transactionWithError) |
void |
FluxUsingWhenTest.cancelWithHandler(Flux<java.lang.String> source) |
void |
FluxUsingWhenTest.cancelWithoutHandlerAppliesCommit(Flux<java.lang.String> source)
已过时。
|
void |
FluxUsingWhenTest.commitGeneratingNull(Flux<java.lang.String> fullTransaction) |
void |
FluxUsingWhenTest.contextPropagationOnCancel(Flux<java.lang.String> source) |
void |
FluxUsingWhenTest.contextPropagationOnCancelWithNoHandler(Flux<java.lang.String> source) |
限定符和类型 | 方法和说明 |
---|---|
<P> P |
Flux.as(java.util.function.Function<? super Flux<T>,P> transformer)
Transform this
Flux into a target type. |
<TRight,TLeftEnd,TRightEnd,R> |
Flux.groupJoin(org.reactivestreams.Publisher<? extends TRight> other,
java.util.function.Function<? super T,? extends org.reactivestreams.Publisher<TLeftEnd>> leftEnd,
java.util.function.Function<? super TRight,? extends org.reactivestreams.Publisher<TRightEnd>> rightEnd,
java.util.function.BiFunction<? super T,? super Flux<TRight>,? extends R> resultSelector)
Map values from two Publishers into time windows and emit combination of values
in case their windows overlap.
|
<R> Flux<R> |
Flux.publish(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<? extends R>> transform)
Shares a sequence for the duration of a function that may transform it and
consume it as many times as necessary without causing multiple subscriptions
to the upstream.
|
<R> Flux<R> |
Flux.publish(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<? extends R>> transform,
int prefetch)
Shares a sequence for the duration of a function that may transform it and
consume it as many times as necessary without causing multiple subscriptions
to the upstream.
|
Flux<T> |
Mono.repeatWhen(java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
Repeatedly subscribe to this
Mono when a companion sequence emits elements in
response to the flux completion signal. |
Flux<T> |
Flux.repeatWhen(java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
Repeatedly subscribe to this
Flux when a companion sequence emits elements in
response to the flux completion signal. |
Mono<T> |
Mono.repeatWhenEmpty(java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
|
Mono<T> |
Mono.repeatWhenEmpty(int maxRepeat,
java.util.function.Function<Flux<java.lang.Long>,? extends org.reactivestreams.Publisher<?>> repeatFactory)
|
<V> Flux<V> |
Flux.switchOnFirst(java.util.function.BiFunction<Signal<? extends T>,Flux<T>,org.reactivestreams.Publisher<? extends V>> transformer)
Transform the current
Flux once it emits its first element, making a
conditional transformation possible. |
<V> Flux<V> |
Flux.switchOnFirst(java.util.function.BiFunction<Signal<? extends T>,Flux<T>,org.reactivestreams.Publisher<? extends V>> transformer,
boolean cancelSourceOnComplete)
Transform the current
Flux once it emits its first element, making a
conditional transformation possible. |
<V> Flux<V> |
Flux.transform(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<V>> transformer)
|
<V> Flux<V> |
Flux.transformDeferred(java.util.function.Function<? super Flux<T>,? extends org.reactivestreams.Publisher<V>> transformer)
|
<V> Flux<V> |
Flux.transformDeferredContextual(java.util.function.BiFunction<? super Flux<T>,? super ContextView,? extends org.reactivestreams.Publisher<V>> transformer)
|
限定符和类型 | 字段和说明 |
---|---|
static java.util.function.Function<? super Flux<java.lang.String>,Flux<java.lang.String>> |
FakeUtils1.applyFilters |
static java.util.function.Function<? super Flux<java.lang.String>,Flux<java.lang.String>> |
FakeUtils1.applyFilters |
static java.util.function.Function<? super Flux<java.lang.String>,Flux<Tuple2<java.lang.Long,java.lang.String>>> |
FakeUtils2.enrichUser |
static java.util.function.Function<? super Flux<java.lang.String>,Flux<Tuple2<java.lang.Long,java.lang.String>>> |
FakeUtils2.enrichUser |
限定符和类型 | 方法和说明 |
---|---|
static Flux<java.lang.String> |
FakeRepository.findAllUserByName(Flux<java.lang.String> source) |
Flux<java.lang.String> |
GuideTests.processOrFallback(Mono<java.lang.String> source,
org.reactivestreams.Publisher<java.lang.String> fallback) |
限定符和类型 | 方法和说明 |
---|---|
static Flux<java.lang.String> |
FakeRepository.findAllUserByName(Flux<java.lang.String> source) |
限定符和类型 | 类和说明 |
---|---|
static class |
MockUtils.TestScannableConnectableFlux<T>
An abstract class that can be used to mock a
Scannable ConnectableFlux . |
限定符和类型 | 方法和说明 |
---|---|
abstract Flux<T> |
TestPublisher.flux()
Convenience method to wrap this
TestPublisher to a Flux . |
Flux<T> |
PublisherProbe.flux()
Return a
Flux version of the probe. |
Flux<T> |
PublisherProbe.DefaultPublisherProbe.flux() |
限定符和类型 | 方法和说明 |
---|---|
FluxOperatorTest.Scenario<I,O> |
FluxOperatorTest.Scenario.applyAllOptions(OperatorScenario<I,Flux<I>,O,Flux<O>> source) |
FluxOperatorTest.Scenario<I,O> |
FluxOperatorTest.Scenario.applyAllOptions(OperatorScenario<I,Flux<I>,O,Flux<O>> source) |
ReduceOperatorTest.Scenario<I,O> |
ReduceOperatorTest.Scenario.applyAllOptions(OperatorScenario<I,Flux<I>,O,Mono<O>> source) |
FluxOperatorTest.Scenario<I,O> |
FluxOperatorTest.scenario(java.util.function.Function<Flux<I>,? extends Flux<O>> scenario) |
FluxOperatorTest.Scenario<I,O> |
FluxOperatorTest.scenario(java.util.function.Function<Flux<I>,? extends Flux<O>> scenario) |
ReduceOperatorTest.Scenario<I,O> |
ReduceOperatorTest.scenario(java.util.function.Function<Flux<I>,? extends Mono<O>> scenario) |
限定符和类型 | 方法和说明 |
---|---|
Flux<java.lang.Long> |
RetrySpec.generateCompanion(Flux<Retry.RetrySignal> flux) |
Flux<java.lang.Long> |
RetryBackoffSpec.generateCompanion(Flux<Retry.RetrySignal> t) |
限定符和类型 | 方法和说明 |
---|---|
Flux<java.lang.Long> |
RetrySpec.generateCompanion(Flux<Retry.RetrySignal> flux) |
abstract org.reactivestreams.Publisher<?> |
Retry.generateCompanion(Flux<Retry.RetrySignal> retrySignals)
Generates the companion publisher responsible for reacting to incoming
Retry.RetrySignal emissions, effectively
deciding when to retry. |
Flux<java.lang.Long> |
RetryBackoffSpec.generateCompanion(Flux<Retry.RetrySignal> t) |
限定符和类型 | 方法和说明 |
---|---|
static Retry |
Retry.from(java.util.function.Function<Flux<Retry.RetrySignal>,? extends org.reactivestreams.Publisher<?>> function)
A wrapper around
Function to provide Retry by using lambda expressions. |
static Retry |
Retry.withThrowable(java.util.function.Function<Flux<java.lang.Throwable>,? extends org.reactivestreams.Publisher<?>> function)
|