diff --git a/src/main/java/io/reactivex/Completable.java b/src/main/java/io/reactivex/Completable.java
index e55c8e382c..d86b6ec628 100644
--- a/src/main/java/io/reactivex/Completable.java
+++ b/src/main/java/io/reactivex/Completable.java
@@ -136,6 +136,9 @@ public static Completable concat(Iterable extends CompletableSource> sources)
/**
* Returns a Completable which completes only when all sources complete, one after another.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -152,6 +155,9 @@ public static Completable concat(Publisher extends CompletableSource> sources)
/**
* Returns a Completable which completes only when all sources complete, one after another.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
{@code create} does not operate by default on a particular {@link Scheduler}.
*
- * @param source the emitter that is called when a Subscriber subscribes to the returned {@code Flowable}
+ * @param source the emitter that is called when a CompletableObserver subscribes to the returned {@code Completable}
* @return the new Completable instance
- * @see FlowableOnSubscribe
+ * @see CompletableOnSubscribe
* @see Cancellable
*/
@SchedulerSupport(SchedulerSupport.NONE)
@@ -249,7 +255,7 @@ public static Completable defer(final Callable extends CompletableSource> comp
* Creates a Completable which calls the given error supplier for each subscriber
* and emits its returned Throwable.
*
- * If the errorSupplier returns null, the child CompletableSubscribers will receive a
+ * If the errorSupplier returns null, the child CompletableObservers will receive a
* NullPointerException.
*
*
Scheduler:
@@ -354,6 +360,9 @@ public static Completable fromObservable(final ObservableSource observabl
* Returns a Completable instance that subscribes to the given publisher, ignores all values and
* emits only the terminal event.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code fromPublisher} does not operate by default on a particular {@link Scheduler}.
*
@@ -431,6 +440,9 @@ public static Completable merge(Iterable extends CompletableSource> sources) {
* Returns a Completable instance that subscribes to all sources at once and
* completes only when all source Completables complete or one of them emits an error.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -448,6 +460,9 @@ public static Completable merge(Publisher extends CompletableSource> sources)
* Returns a Completable instance that keeps subscriptions to a limited number of sources at once and
* completes only when all source Completables complete or one of them emits an error.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -468,6 +483,9 @@ public static Completable merge(Publisher extends CompletableSource> sources,
* completes only when all source Completables terminate in one way or another, combining any exceptions
* thrown by either the sources Observable or the inner Completable instances.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code merge0} does not operate by default on a particular {@link Scheduler}.
*
@@ -528,6 +546,9 @@ public static Completable mergeDelayError(Iterable extends CompletableSource>
* any error emitted by either the sources observable or any of the inner Completables until all of
* them terminate in a way or another.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code mergeDelayError} does not operate by default on a particular {@link Scheduler}.
*
@@ -547,6 +568,9 @@ public static Completable mergeDelayError(Publisher extends CompletableSource>
* observable or any of the inner Completables until all of
* them terminate in a way or another.
*
+ *
Backpressure:
+ *
The returned {@code Completable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code mergeDelayError} does not operate by default on a particular {@link Scheduler}.
*
@@ -732,11 +756,14 @@ public final Observable andThen(ObservableSource next) {
}
/**
- * Returns an Flowable which will subscribe to this Completable and once that is completed then
+ * Returns a Flowable which will subscribe to this Completable and once that is completed then
* will subscribe to the {@code next} Flowable. An error event from this Completable will be
* propagated to the downstream subscriber and will result in skipping the subscription of the
* Observable.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code andThen} does not operate by default on a particular {@link Scheduler}.
*
@@ -1387,6 +1414,9 @@ public final Observable startWith(Observable other) {
* Returns an Observable which first delivers the events
* of the other Observable then runs this Completable.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and expects the other {@code Publisher} to honor it as well.
*
Scheduler:
*
{@code startWith} does not operate by default on a particular {@link Scheduler}.
*
@@ -1659,6 +1689,8 @@ public final U to(Function super Completable, U> converter) {
* Returns an Observable which when subscribed to subscribes to this Completable and
* relays the terminal events to the subscriber.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code toFlowable} does not operate by default on a particular {@link Scheduler}.
*
diff --git a/src/main/java/io/reactivex/Flowable.java b/src/main/java/io/reactivex/Flowable.java
index 3f2931d909..de24cf696b 100644
--- a/src/main/java/io/reactivex/Flowable.java
+++ b/src/main/java/io/reactivex/Flowable.java
@@ -408,7 +408,7 @@ public static Flowable combineLatestDelayError(Function super Object
/**
* Combines a collection of source Publishers by emitting an item that aggregates the latest values of each of
- * the source ObservableSources each time an item is received from any of the source Publisher, where this
+ * the source Publishers each time an item is received from any of the source Publisher, where this
* aggregation is defined by a specified function and delays any error from the sources until
* all source Publishers terminate.
*
@@ -1274,7 +1274,7 @@ public static Flowable concatArrayDelayError(Publisher extends T>... so
* in order, each one after the previous one completes.
*
*
Backpressure:
- *
The operator honors backpressure from downstream. The {@code Publisher}
+ *
The operator honors backpressure from downstream. The {@code Publisher}
* sources are expected to honor backpressure as well.
* If any of the source {@code Publisher}s violate this, the operator will signal a
* {@code MissingBackpressureException}.
@@ -1300,7 +1300,7 @@ public static Flowable concatArrayEager(Publisher extends T>... sources
* in order, each one after the previous one completes.
*
*
Backpressure:
- *
The operator honors backpressure from downstream. The {@code Publisher}
+ *
The operator honors backpressure from downstream. The {@code Publisher}
* sources are expected to honor backpressure as well.
* If any of the source {@code Publisher}s violate this, the operator will signal a
* {@code MissingBackpressureException}.
* The defer Subscriber allows you to defer or delay emitting items from a Publisher until such time as an
- * Subscriber subscribes to the Publisher. This allows an {@link Subscriber} to easily obtain updates or a
+ * Subscriber subscribes to the Publisher. This allows a {@link Subscriber} to easily obtain updates or a
* refreshed version of the sequence.
*
*
Backpressure:
@@ -1616,7 +1616,7 @@ public static Flowable empty() {
}
/**
- * Returns a Flowable that invokes an {@link Subscriber}'s {@link Subscriber#onError onError} method when the
+ * Returns a Flowable that invokes a {@link Subscriber}'s {@link Subscriber#onError onError} method when the
* Subscriber subscribes to it.
*
*
@@ -1643,7 +1643,7 @@ public static Flowable error(Callable extends Throwable> supplier) {
}
/**
- * Returns a Flowable that invokes an {@link Subscriber}'s {@link Subscriber#onError onError} method when the
+ * Returns a Flowable that invokes a {@link Subscriber}'s {@link Subscriber#onError onError} method when the
* Subscriber subscribes to it.
*
*
@@ -1702,12 +1702,12 @@ public static Flowable fromArray(T... items) {
}
/**
- * Returns a Flowable that, when an Subscriber subscribes to it, invokes a function you specify and then
+ * Returns a Flowable that, when a Subscriber subscribes to it, invokes a function you specify and then
* emits the value returned from that function.
*
*
*
- * This allows you to defer the execution of the function you specify until an Subscriber subscribes to the
+ * This allows you to defer the execution of the function you specify until a Subscriber subscribes to the
* Publisher. That is to say, it makes the function "lazy."
*
*
Backpressure:
@@ -1718,7 +1718,7 @@ public static Flowable fromArray(T... items) {
*
* @param supplier
* a function, the execution of which should be deferred; {@code fromCallable} will invoke this
- * function only when an Subscriber subscribes to the Publisher that {@code fromCallable} returns
+ * function only when a Subscriber subscribes to the Publisher that {@code fromCallable} returns
* @param
* the type of the item emitted by the Publisher
* @return a Flowable whose {@link Subscriber}s' subscriptions trigger an invocation of the given function
@@ -2151,7 +2151,7 @@ public static Flowable interval(long initialDelay, long period, TimeUnit u
*
*
Backpressure:
*
The operator signals a {@code MissingBackpressureException} if the downstream
- * is not ready to receive the next value.
+ * is not ready to receive the next value.
*
Scheduler:
*
{@code interval} operates by default on the {@code computation} {@link Scheduler}.
*
@@ -3007,7 +3007,7 @@ public static Flowable merge(
}
/**
- * Flattens an Iterable of Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens an Iterable of Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them.
*
@@ -3043,7 +3043,7 @@ public static Flowable mergeDelayError(Iterable extends Publisher ext
/**
- * Flattens an Iterable of Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens an Iterable of Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them, while limiting the number of concurrent subscriptions to these Publishers.
*
@@ -3082,7 +3082,7 @@ public static Flowable mergeDelayError(Iterable extends Publisher ext
}
/**
- * Flattens an array of Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens an array of Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them, while limiting the number of concurrent subscriptions to these Publishers.
*
@@ -3121,7 +3121,7 @@ public static Flowable mergeArrayDelayError(int maxConcurrency, int buffe
}
/**
- * Flattens an Iterable of Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens an Iterable of Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them, while limiting the number of concurrent subscriptions to these Publishers.
*
@@ -3158,7 +3158,7 @@ public static Flowable mergeDelayError(Iterable extends Publisher ext
}
/**
- * Flattens a Publisher that emits Publishers into one Publisher, in a way that allows an Subscriber to
+ * Flattens a Publisher that emits Publishers into one Publisher, in a way that allows a Subscriber to
* receive all successfully emitted items from all of the source Publishers without being interrupted by
* an error notification from one of them.
*
@@ -3193,7 +3193,7 @@ public static Flowable mergeDelayError(Publisher extends Publisher ex
}
/**
- * Flattens a Publisher that emits Publishers into one Publisher, in a way that allows an Subscriber to
+ * Flattens a Publisher that emits Publishers into one Publisher, in a way that allows a Subscriber to
* receive all successfully emitted items from all of the source Publishers without being interrupted by
* an error notification from one of them, while limiting the
* number of concurrent subscriptions to these Publishers.
@@ -3232,7 +3232,7 @@ public static Flowable mergeDelayError(Publisher extends Publisher ex
}
/**
- * Flattens an array of Publishers into one Flowable, in a way that allows an Subscriber to receive all
+ * Flattens an array of Publishers into one Flowable, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them.
*
@@ -3267,7 +3267,7 @@ public static Flowable mergeArrayDelayError(Publisher extends T>... sou
}
/**
- * Flattens two Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens two Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source Publishers without being interrupted by an error
* notification from one of them.
*
@@ -3305,7 +3305,7 @@ public static Flowable mergeDelayError(Publisher extends T> source1, Pu
}
/**
- * Flattens three Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens three Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from all of the source Publishers without being interrupted by an error
* notification from one of them.
*
@@ -3348,7 +3348,7 @@ public static Flowable mergeDelayError(Publisher extends T> source1, Pu
/**
- * Flattens four Publishers into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens four Publishers into one Publisher, in a way that allows a Subscriber to receive all
* successfully emitted items from all of the source Publishers without being interrupted by an error
* notification from one of them.
*
@@ -3395,7 +3395,7 @@ public static Flowable mergeDelayError(
}
/**
- * Returns a Flowable that never sends any items or notifications to an {@link Subscriber}.
+ * Returns a Flowable that never sends any items or notifications to a {@link Subscriber}.
*
*
*
@@ -3409,7 +3409,7 @@ public static Flowable mergeDelayError(
*
* @param
* the type of items (not) emitted by the Publisher
- * @return a Flowable that never emits any items or sends any notifications to an {@link Subscriber}
+ * @return a Flowable that never emits any items or sends any notifications to a {@link Subscriber}
* @see ReactiveX operators documentation: Never
*/
@BackpressureSupport(BackpressureKind.PASS_THROUGH)
diff --git a/src/main/java/io/reactivex/Maybe.java b/src/main/java/io/reactivex/Maybe.java
index bf9eae10b7..785a6a4d98 100644
--- a/src/main/java/io/reactivex/Maybe.java
+++ b/src/main/java/io/reactivex/Maybe.java
@@ -86,6 +86,8 @@ public static Maybe ambArray(final MaybeSource extends T>... sources) {
* Concatenate the single values, in a non-overlapping fashion, of the MaybeSource sources provided by
* an Iterable sequence.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -103,8 +105,10 @@ public static Flowable concat(Iterable extends MaybeSource extends T>
/**
* Returns a Flowable that emits the items emitted by two MaybeSources, one after the other.
*
- *
+ *
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -129,8 +133,10 @@ public static Flowable concat(MaybeSource extends T> source1, MaybeSour
/**
* Returns a Flowable that emits the items emitted by three MaybeSources, one after the other.
*
- *
+ *
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -159,8 +165,10 @@ public static Flowable concat(
/**
* Returns a Flowable that emits the items emitted by four MaybeSources, one after the other.
*
- *
+ *
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -193,8 +201,12 @@ public static Flowable concat(
* Concatenate the single values, in a non-overlapping fashion, of the MaybeSource sources provided by
* a Publisher sequence.
*
- *
Scheduler:
- *
{@code concat} does not operate by default on a particular {@link Scheduler}.
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer and
+ * expects the {@code Publisher} to honor backpressure as well. If the sources {@code Publisher}
+ * violates this, a {@code MissingBackpressurException} is signalled.
+ *
Scheduler:
+ *
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
* @param the value type
* @param sources the Publisher of MaybeSource instances
@@ -210,6 +222,10 @@ public static Flowable concat(Publisher extends MaybeSource extends T
* Concatenate the single values, in a non-overlapping fashion, of the MaybeSource sources provided by
* a Publisher sequence.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer and
+ * expects the {@code Publisher} to honor backpressure as well. If the sources {@code Publisher}
+ * violates this, a {@code MissingBackpressurException} is signalled.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -230,11 +246,13 @@ public static Flowable concat(Publisher extends MaybeSource extends T
/**
* Concatenate the single values, in a non-overlapping fashion, of the MaybeSource sources in the array.
*
- *
Scheduler:
- *
{@code concatArray} does not operate by default on a particular {@link Scheduler}.
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
+ *
Scheduler:
+ *
{@code concatArray} does not operate by default on a particular {@link Scheduler}.
*
* @param the value type
- * @param sources the Publisher of MaybeSource instances
+ * @param sources the array of MaybeSource instances
* @return the new Flowable instance
*/
@BackpressureSupport(BackpressureKind.FULL)
@@ -258,9 +276,7 @@ public static Flowable concatArray(MaybeSource extends T>... sources) {
*
*
*
Backpressure:
- *
The operator honors backpressure from downstream.
- * If the {@code Publisher} violate this, it may throw an
- * {@code IllegalStateException} when the source {@code Publisher} completes.
+ *
The operator honors backpressure from downstream.
*
Scheduler:
*
{@code concatArrayDelayError} does not operate by default on a particular {@link Scheduler}.
*
@@ -290,7 +306,7 @@ public static Flowable concatArrayDelayError(MaybeSource extends T>...
* in order, each one after the previous one completes.
*
*
Backpressure:
- *
The operator honors backpressure from downstream.
+ *
The operator honors backpressure from downstream.
*
Scheduler:
*
This method does not operate by default on a particular {@link Scheduler}.
*
@@ -306,22 +322,19 @@ public static Flowable concatArrayEager(MaybeSource extends T>... sourc
}
/**
- * Concatenates the Iterable sequence of Publishers into a single sequence by subscribing to each Publisher,
- * one after the other, one at a time and delays any errors till the all inner Publishers terminate.
+ * Concatenates the Iterable sequence of MaybeSources into a single sequence by subscribing to each MaybeSource,
+ * one after the other, one at a time and delays any errors till the all inner MaybeSources terminate.
*
*
*
Backpressure:
- *
The operator honors backpressure from downstream. The inner {@code Publisher}
- * sources are expected to honor backpressure. If any of the inner {@code Publisher}s violates
- * this, it may throw an {@code IllegalStateException} when an
- * inner {@code Publisher} completes.
+ *
The operator honors backpressure from downstream.
*
Scheduler:
*
{@code concatDelayError} does not operate by default on a particular {@link Scheduler}.
*
*
* @param the common element base type
* @param sources the Iterable sequence of MaybeSources
- * @return the new Publisher with the concatenating behavior
+ * @return the new Flowable with the concatenating behavior
*/
@SuppressWarnings({ "unchecked", "rawtypes" })
@BackpressureSupport(BackpressureKind.FULL)
@@ -361,9 +374,7 @@ public static Flowable concatDelayError(Publisher extends MaybeSource
* in order, each one after the previous one completes.
*
*
Backpressure:
- *
Backpressure is honored towards the downstream and outer Publisher is expected
- * to honor backpressure. Violating this assumption, the operator will
- * signal {@code MissingBackpressureException}.
+ *
Backpressure is honored towards the downstream.
*
Scheduler:
*
This method does not operate by default on a particular {@link Scheduler}.
{@code create} does not operate by default on a particular {@link Scheduler}.
*
* @param the value type
- * @param onSubscribe the emitter that is called when a MaybeObserver subscribes to the returned {@code Flowable}
+ * @param onSubscribe the emitter that is called when a MaybeObserver subscribes to the returned {@code Maybe}
* @return the new Maybe instance
* @see MaybeOnSubscribe
* @see Cancellable
@@ -488,7 +499,7 @@ public static Maybe empty() {
* Returns a Maybe that invokes a subscriber's {@link MaybeObserver#onError onError} method when the
* subscriber subscribes to it.
*
- *
+ *
*
*
Scheduler:
*
{@code error} does not operate by default on a particular {@link Scheduler}.
@@ -509,8 +520,8 @@ public static Maybe error(Throwable exception) {
}
/**
- * Returns a Maybe that invokes an {@link Observer}'s {@link MaybeObserver#onError onError} method when the
- * Observer subscribes to it.
+ * Returns a Maybe that invokes a {@link MaybeObserver}'s {@link MaybeObserver#onError onError} method when the
+ * MaybeObserver subscribes to it.
*
*
* @param supplier
- * a Callable factory to return a Throwable for each individual Subscriber
+ * a Callable factory to return a Throwable for each individual MaybeObserver
* @param
* the type of the items (ostensibly) emitted by the Maybe
* @return a Maybe that invokes the {@link MaybeObserver}'s {@link MaybeObserver#onError onError} method when
@@ -596,7 +607,7 @@ public static Maybe fromCallable(final Callable extends T> callable) {
* the source {@link Future}
* @param
* the type of object that the {@link Future} returns, and also the type of item to be emitted by
- * the resulting Publisher
+ * the resulting Maybe
* @return a Maybe that emits the item from the source {@link Future}
* @see ReactiveX operators documentation: From
*/
@@ -615,13 +626,11 @@ public static Maybe fromFuture(Future extends T> future) {
* return value of the {@link Future#get} method of that object, by passing the object into the {@code fromFuture}
* method.
*
- * Unlike 1.x, cancelling the Flowable won't cancel the future. If necessary, one can use composition to achieve the
+ * Unlike 1.x, cancelling the Maybe won't cancel the future. If necessary, one can use composition to achieve the
* cancellation effect: {@code futureMaybe.doOnCancel(() -> future.cancel(true));}.
*
* Important note: This Maybe is blocking on the thread it gets subscribed on; you cannot unsubscribe from it.
*
- *
Backpressure:
- *
The operator honors backpressure from downstream.
*
Scheduler:
*
{@code fromFuture} does not operate by default on a particular {@link Scheduler}.
*
@@ -634,7 +643,7 @@ public static Maybe fromFuture(Future extends T> future) {
* the {@link TimeUnit} of the {@code timeout} argument
* @param
* the type of object that the {@link Future} returns, and also the type of item to be emitted by
- * the resulting Publisher
+ * the resulting Maybe
* @return a Maybe that emits the item from the source {@link Future}
* @see ReactiveX operators documentation: From
*/
@@ -667,9 +676,9 @@ public static Maybe fromRunnable(final Runnable run) {
/**
* Returns a {@code Maybe} that emits a specified item.
*
- *
+ *
*
- * To convert any object into a {@code Single} that emits that object, pass that object into the
+ * To convert any object into a {@code Maybe} that emits that object, pass that object into the
* {@code just} method.
*
*
Scheduler:
@@ -749,10 +758,10 @@ public static Flowable merge(Publisher extends MaybeSource extends T>
}
/**
- * Flattens a {@code Single} that emits a {@code Single} into a single {@code Single} that emits the item
- * emitted by the nested {@code Single}, without any transformation.
+ * Flattens a {@code MaybeSource} that emits a {@code MaybeSource} into a single {@code MaybeSource} that emits the item
+ * emitted by the nested {@code MaybeSource}, without any transformation.
*
- *
+ *
*
*
*
Scheduler:
@@ -761,8 +770,8 @@ public static Flowable merge(Publisher extends MaybeSource extends T>
*
* @param the value type of the sources and the output
* @param source
- * a {@code Single} that emits a {@code Single}
- * @return a {@code Single} that emits the item that is the result of flattening the {@code Single} emitted
+ * a {@code MaybeSource} that emits a {@code MaybeSource}
+ * @return a {@code Maybe} that emits the item that is the result of flattening the {@code MaybeSource} emitted
* by {@code source}
* @see ReactiveX operators documentation: Merge
*/
@@ -773,11 +782,11 @@ public static Maybe merge(MaybeSource extends MaybeSource extends T>>
}
/**
- * Flattens two Singles into a single Observable, without any transformation.
+ * Flattens two MaybeSources into a single Flowable, without any transformation.
*
- *
+ *
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by
+ * You can combine items emitted by multiple MaybeSources so that they appear as a single Flowable, by
* using the {@code merge} method.
*
*
Backpressure:
@@ -788,10 +797,10 @@ public static Maybe merge(MaybeSource extends MaybeSource extends T>>
*
* @param the common value type
* @param source1
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source2
- * a Single to be merged
- * @return a Flowable that emits all of the items emitted by the source Singles
+ * a MaybeSource to be merged
+ * @return a Flowable that emits all of the items emitted by the source MaybeSources
* @see ReactiveX operators documentation: Merge
*/
@BackpressureSupport(BackpressureKind.FULL)
@@ -806,11 +815,11 @@ public static Flowable merge(
}
/**
- * Flattens three Singles into a single Observable, without any transformation.
+ * Flattens three MaybeSources into a single Flowable, without any transformation.
*
- *
+ *
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by using
+ * You can combine items emitted by multiple MaybeSources so that they appear as a single Flowable, by using
* the {@code merge} method.
*
*
Backpressure:
@@ -821,12 +830,12 @@ public static Flowable merge(
*
* @param the common value type
* @param source1
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source2
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source3
- * a Single to be merged
- * @return a Flowable that emits all of the items emitted by the source Singles
+ * a MaybeSource to be merged
+ * @return a Flowable that emits all of the items emitted by the source MaybeSources
* @see ReactiveX operators documentation: Merge
*/
@BackpressureSupport(BackpressureKind.FULL)
@@ -843,11 +852,11 @@ public static Flowable merge(
}
/**
- * Flattens four Singles into a single Observable, without any transformation.
+ * Flattens four MaybeSources into a single Flowable, without any transformation.
*
- *
+ *
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by using
+ * You can combine items emitted by multiple MaybeSources so that they appear as a single Flowable, by using
* the {@code merge} method.
*
*
Backpressure:
@@ -858,14 +867,14 @@ public static Flowable merge(
*
* @param the common value type
* @param source1
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source2
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source3
- * a Single to be merged
+ * a MaybeSource to be merged
* @param source4
- * a Single to be merged
- * @return a Flowable that emits all of the items emitted by the source Singles
+ * a MaybeSource to be merged
+ * @return a Flowable that emits all of the items emitted by the source MaybeSources
* @see ReactiveX operators documentation: Merge
*/
@BackpressureSupport(BackpressureKind.FULL)
@@ -910,17 +919,17 @@ public static Flowable mergeArray(MaybeSource extends T>... sources) {
}
/**
- * Flattens an array of MaybeSources into one Publisher, in a way that allows an Subscriber to receive all
+ * Flattens an array of MaybeSources into one Flowable, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source MaybeSources without being interrupted by an error
* notification from one of them.
*
* This behaves like {@link #merge(Publisher)} except that if any of the merged MaybeSources notify of an
* error via {@link Subscriber#onError onError}, {@code mergeDelayError} will refrain from propagating that
- * error notification until all of the merged Publishers have finished emitting items.
+ * error notification until all of the merged MaybeSources have finished emitting items.
*
*
*
- * Even if multiple merged Publishers send {@code onError} notifications, {@code mergeDelayError} will only
+ * Even if multiple merged MaybeSources send {@code onError} notifications, {@code mergeDelayError} will only
* invoke the {@code onError} method of its Subscribers once.
*
*
Backpressure:
@@ -933,7 +942,7 @@ public static Flowable mergeArray(MaybeSource extends T>... sources) {
* @param sources
* the Iterable of MaybeSources
* @return a Flowable that emits items that are the result of flattening the items emitted by the
- * Publishers in the Iterable
+ * MaybeSources in the Iterable
* @see ReactiveX operators documentation: Merge
*/
@SuppressWarnings({ "unchecked", "rawtypes" })
@@ -945,17 +954,17 @@ public static Flowable mergeArrayDelayError(MaybeSource extends T>... s
/**
- * Flattens an Iterable of MaybeSources into one Publisher, in a way that allows an Subscriber to receive all
- * successfully emitted items from each of the source Publishers without being interrupted by an error
+ * Flattens an Iterable of MaybeSources into one Flowable, in a way that allows a Subscriber to receive all
+ * successfully emitted items from each of the source MaybeSources without being interrupted by an error
* notification from one of them.
*
- * This behaves like {@link #merge(Publisher)} except that if any of the merged Publishers notify of an
+ * This behaves like {@link #merge(Publisher)} except that if any of the merged MaybeSources notify of an
* error via {@link Subscriber#onError onError}, {@code mergeDelayError} will refrain from propagating that
- * error notification until all of the merged Publishers have finished emitting items.
+ * error notification until all of the merged MaybeSources have finished emitting items.
*
*
*
- * Even if multiple merged Publishers send {@code onError} notifications, {@code mergeDelayError} will only
+ * Even if multiple merged MaybeSources send {@code onError} notifications, {@code mergeDelayError} will only
* invoke the {@code onError} method of its Subscribers once.
*
*
Backpressure:
@@ -966,9 +975,9 @@ public static Flowable mergeArrayDelayError(MaybeSource extends T>... s
*
* @param the common element base type
* @param sources
- * the Iterable of Publishers
+ * the Iterable of MaybeSources
* @return a Flowable that emits items that are the result of flattening the items emitted by the
- * Publishers in the Iterable
+ * MaybeSources in the Iterable
* @see ReactiveX operators documentation: Merge
*/
@SuppressWarnings({ "unchecked", "rawtypes" })
@@ -980,7 +989,7 @@ public static Flowable mergeDelayError(Iterable extends MaybeSource e
/**
- * Flattens a Publisher that emits MaybeSources into one Publisher, in a way that allows an Subscriber to
+ * Flattens a Publisher that emits MaybeSources into one Publisher, in a way that allows a Subscriber to
* receive all successfully emitted items from all of the source Publishers without being interrupted by
* an error notification from one of them.
*
@@ -1015,7 +1024,7 @@ public static Flowable mergeDelayError(Publisher extends MaybeSource
}
/**
- * Flattens two MaybeSources into one Flowable, in a way that allows an Subscriber to receive all
+ * Flattens two MaybeSources into one Flowable, in a way that allows a Subscriber to receive all
* successfully emitted items from each of the source MaybeSources without being interrupted by an error
* notification from one of them.
*
- * Even if both merged Publishers send {@code onError} notifications, {@code mergeDelayError} will only
+ * Even if both merged MaybeSources send {@code onError} notifications, {@code mergeDelayError} will only
* invoke the {@code onError} method of its Subscribers once.
*
*
Backpressure:
@@ -1052,18 +1061,18 @@ public static Flowable mergeDelayError(MaybeSource extends T> source1,
}
/**
- * Flattens three MaybeSource into one Flowable, in a way that allows an Subscriber to receive all
+ * Flattens three MaybeSource into one Flowable, in a way that allows a Subscriber to receive all
* successfully emitted items from all of the source MaybeSources without being interrupted by an error
* notification from one of them.
*
* This behaves like {@link #merge(MaybeSource, MaybeSource, MaybeSource)} except that if any of the merged
- * Publishers notify of an error via {@link Subscriber#onError onError}, {@code mergeDelayError} will refrain
- * from propagating that error notification until all of the merged Publishers have finished emitting
+ * MaybeSources notify of an error via {@link Subscriber#onError onError}, {@code mergeDelayError} will refrain
+ * from propagating that error notification until all of the merged MaybeSources have finished emitting
* items.
*
*
*
- * Even if multiple merged Publishers send {@code onError} notifications, {@code mergeDelayError} will only
+ * Even if multiple merged MaybeSources send {@code onError} notifications, {@code mergeDelayError} will only
* invoke the {@code onError} method of its Subscribers once.
*
*
Backpressure:
@@ -1074,7 +1083,7 @@ public static Flowable mergeDelayError(MaybeSource extends T> source1,
*
* @param the common element base type
* @param source1
- * a PublMaybeSourceisher to be merged
+ * a MaybeSource to be merged
* @param source2
* a MaybeSource to be merged
* @param source3
@@ -1095,18 +1104,18 @@ public static Flowable mergeDelayError(MaybeSource extends T> source1,
/**
- * Flattens four MaybeSources into one Flowable, in a way that allows an Subscriber to receive all
- * successfully emitted items from all of the source Publishers without being interrupted by an error
+ * Flattens four MaybeSources into one Flowable, in a way that allows a Subscriber to receive all
+ * successfully emitted items from all of the source MaybeSources without being interrupted by an error
* notification from one of them.
*
* This behaves like {@link #merge(MaybeSource, MaybeSource, MaybeSource, MaybeSource)} except that if any of
- * the merged Publishers notify of an error via {@link Subscriber#onError onError}, {@code mergeDelayError}
+ * the merged MaybeSources notify of an error via {@link Subscriber#onError onError}, {@code mergeDelayError}
* will refrain from propagating that error notification until all of the merged MaybeSources have finished
* emitting items.
*
*
*
- * Even if multiple merged Publishers send {@code onError} notifications, {@code mergeDelayError} will only
+ * Even if multiple merged MaybeSources send {@code onError} notifications, {@code mergeDelayError} will only
* invoke the {@code onError} method of its Subscribers once.
*
*
Backpressure:
@@ -1141,7 +1150,7 @@ public static Flowable mergeDelayError(
}
/**
- * Returns a Maybe that never sends any items or notifications to an {@link MaybeObserver}.
+ * Returns a Maybe that never sends any items or notifications to a {@link MaybeObserver}.
*
*
*
@@ -1153,7 +1162,7 @@ public static Flowable mergeDelayError(
*
* @param
* the type of items (not) emitted by the Maybe
- * @return a Maybe that never emits any items or sends any notifications to an {@link MaybeObserver}
+ * @return a Maybe that never emits any items or sends any notifications to a {@link MaybeObserver}
* @see ReactiveX operators documentation: Never
*/
@SchedulerSupport(SchedulerSupport.NONE)
@@ -1165,7 +1174,7 @@ public static Maybe never() {
/**
* Returns a Single that emits a Boolean value that indicates whether two MaybeSource sequences are the
- * same by comparing the items emitted by each Publisher pairwise.
+ * same by comparing the items emitted by each MaybeSource pairwise.
*
*
*
@@ -1238,7 +1247,7 @@ public static Maybe timer(long delay, TimeUnit unit) {
}
/**
- * Returns a Flowable that emits one item after a specified delay on a specified Scheduler.
+ * Returns a Maybe that emits one item after a specified delay on a specified Scheduler.
*
{@code using} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the element type of the generated Publisher
+ * @param the element type of the generated MaybeSource
* @param the type of the resource associated with the output sequence
* @param resourceSupplier
* the factory function to create a resource object that depends on the Maybe
@@ -1323,7 +1332,7 @@ public static Maybe using(Callable extends D> resourceSupplier,
*
{@code using} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the element type of the generated Publisher
+ * @param the element type of the generated MaybeSource
* @param the type of the resource associated with the output sequence
* @param resourceSupplier
* the factory function to create a resource object that depends on the Maybe
@@ -2161,7 +2170,7 @@ public final Maybe delay(Publisher delayIndicator) {
* until the other Publisher emits an element or completes normally.
*
*
- *
+ *
Backpressure:
*
The {@code Publisher} source is consumed in an unbounded fashion (without applying backpressure).
*
Scheduler:
*
This method does not operate by default on a particular {@link Scheduler}.
@@ -2496,8 +2505,8 @@ public final Maybe flatMap(Function super T, ? extends MaybeSource
}
/**
- * Returns a Observable that is based on applying a specified function to the item emitted by the source Maybe,
- * where that function returns a ObservableSource.
+ * Returns an Observable that is based on applying a specified function to the item emitted by the source Maybe,
+ * where that function returns an ObservableSource.
*
*
*
@@ -2507,7 +2516,7 @@ public final Maybe flatMap(Function super T, ? extends MaybeSource
*
* @param the result value type
* @param mapper
- * a function that, when applied to the item emitted by the source Maybe, returns a ObservableSource
+ * a function that, when applied to the item emitted by the source Maybe, returns an ObservableSource
* @return the Observable returned from {@code func} when applied to the item emitted by the source Maybe
* @see ReactiveX operators documentation: FlatMap
*/
@@ -2993,6 +3002,302 @@ public final Maybe onExceptionResumeNext(final MaybeSource extends T> next)
ObjectHelper.requireNonNull(next, "next is null");
return RxJavaPlugins.onAssembly(new MaybeOnErrorNext(this, Functions.justFunction(next), false));
}
+ /**
+ * Nulls out references to the upstream producer and downstream MaybeObserver if
+ * the sequence is terminated or downstream unsubscribes.
+ *
+ *
Scheduler:
+ *
{@code onTerminateDetach} does not operate by default on a particular {@link Scheduler}.
+ *
+ * @return a Maybe which out references to the upstream producer and downstream MaybeObserver if
+ * the sequence is terminated or downstream unsubscribes
+ */
+ @SchedulerSupport(SchedulerSupport.NONE)
+ public final Maybe onTerminateDetach() {
+ return RxJavaPlugins.onAssembly(new MaybeDetach(this));
+ }
+
+ /**
+ * Returns a Flowable that repeats the sequence of items emitted by the source Publisher indefinitely.
+ *
+ *
+ *
+ *
Backpressure:
+ *
The operator honors downstream backpressure and expects the source {@code Publisher} to honor backpressure as well.
+ * If this expectation is violated, the operator may throw an {@code IllegalStateException}.
+ *
Scheduler:
+ *
{@code repeat} does not operate by default on a particular {@link Scheduler}.
+ *
+ *
+ * @return a Flowable that emits the items emitted by the source Publisher repeatedly and in sequence
+ * @see ReactiveX operators documentation: Repeat
+ */
+ @BackpressureSupport(BackpressureKind.FULL)
+ @SchedulerSupport(SchedulerSupport.NONE)
+ public final Flowable repeat() {
+ return repeat(Long.MAX_VALUE);
+ }
+
+ /**
+ * Returns a Flowable that repeats the sequence of items emitted by the source Publisher at most
+ * {@code count} times.
+ *
+ *
+ *
+ *
Backpressure:
+ *
The operator honors downstream backpressure and expects the source {@code Publisher} to honor backpressure as well.
+ * If this expectation is violated, the operator may throw an {@code IllegalStateException}.
+ *
Scheduler:
+ *
{@code repeat} does not operate by default on a particular {@link Scheduler}.
+ *
+ *
+ * @param times
+ * the number of times the source Publisher items are repeated, a count of 0 will yield an empty
+ * sequence
+ * @return a Flowable that repeats the sequence of items emitted by the source Publisher at most
+ * {@code count} times
+ * @throws IllegalArgumentException
+ * if {@code count} is less than zero
+ * @see ReactiveX operators documentation: Repeat
+ */
+ @BackpressureSupport(BackpressureKind.FULL)
+ @SchedulerSupport(SchedulerSupport.NONE)
+ public final Flowable repeat(long times) {
+ return toFlowable().repeat(times);
+ }
+
+ /**
+ * Returns a Flowable that repeats the sequence of items emitted by the source Publisher until
+ * the provided stop function returns true.
+ *
+ *
+ *
+ *
Backpressure:
+ *
The operator honors downstream backpressure and expects the source {@code Publisher} to honor backpressure as well.
+ * If this expectation is violated, the operator may throw an {@code IllegalStateException}.
+ *
Scheduler:
+ *
{@code repeatUntil} does not operate by default on a particular {@link Scheduler}.
+ *
+ *
+ * @param stop
+ * a boolean supplier that is called when the current Flowable completes and unless it returns
+ * false, the current Flowable is resubscribed
+ * @return the new Flowable instance
+ * @throws NullPointerException
+ * if {@code stop} is null
+ * @see ReactiveX operators documentation: Repeat
+ */
+ @BackpressureSupport(BackpressureKind.FULL)
+ @SchedulerSupport(SchedulerSupport.NONE)
+ public final Flowable repeatUntil(BooleanSupplier stop) {
+ return toFlowable().repeatUntil(stop);
+ }
+
+ /**
+ * Returns a Flowable that emits the same values as the source Publisher with the exception of an
+ * {@code onComplete}. An {@code onComplete} notification from the source will result in the emission of
+ * a {@code void} item to the Publisher provided as an argument to the {@code notificationHandler}
+ * function. If that Publisher calls {@code onComplete} or {@code onError} then {@code repeatWhen} will
+ * call {@code onComplete} or {@code onError} on the child subscription. Otherwise, this Publisher will
+ * resubscribe to the source Publisher.
+ *
+ *
+ *
+ *
Backpressure:
+ *
The operator honors downstream backpressure and expects the source {@code Publisher} to honor backpressure as well.
+ * If this expectation is violated, the operator may throw an {@code IllegalStateException}.
+ *
Scheduler:
+ *
{@code repeatWhen} does not operate by default on a particular {@link Scheduler}.
+ *
+ *
+ * @param handler
+ * receives a Publisher of notifications with which a user can complete or error, aborting the repeat.
+ * @return the source Publisher modified with repeat logic
+ * @see ReactiveX operators documentation: Repeat
+ */
+ @BackpressureSupport(BackpressureKind.FULL)
+ @SchedulerSupport(SchedulerSupport.NONE)
+ public final Flowable repeatWhen(final Function super Flowable
*
* @param the generated value type
- * @param generator the Consumer called whenever a particular downstream Subscriber has
+ * @param generator the Consumer called whenever a particular downstream Observer has
* requested a value. The callback then should call {@code onNext}, {@code onError} or
* {@code onComplete} to signal a value or a terminal event. Signalling multiple {@code onNext}
* in a call will make the operator signal {@code IllegalStateException}.
@@ -1661,10 +1661,10 @@ public static Observable generate(final Consumer> generator) {
*
{@code generate} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the type of the per-Subscriber state
+ * @param the type of the per-Observer state
* @param the generated value type
- * @param initialState the Callable to generate the initial state for each Subscriber
- * @param generator the Consumer called with the current state whenever a particular downstream Subscriber has
+ * @param initialState the Callable to generate the initial state for each Observer
+ * @param generator the Consumer called with the current state whenever a particular downstream Observer has
* requested a value. The callback then should call {@code onNext}, {@code onError} or
* {@code onComplete} to signal a value or a terminal event. Signalling multiple {@code onNext}
* in a call will make the operator signal {@code IllegalStateException}.
@@ -1684,10 +1684,10 @@ public static Observable generate(Callable initialState, final BiCo
*
{@code generate} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the type of the per-Subscriber state
+ * @param the type of the per-Observer state
* @param the generated value type
- * @param initialState the Callable to generate the initial state for each Subscriber
- * @param generator the Consumer called with the current state whenever a particular downstream Subscriber has
+ * @param initialState the Callable to generate the initial state for each Observer
+ * @param generator the Consumer called with the current state whenever a particular downstream Observer has
* requested a value. The callback then should call {@code onNext}, {@code onError} or
* {@code onComplete} to signal a value or a terminal event. Signalling multiple {@code onNext}
* in a call will make the operator signal {@code IllegalStateException}.
@@ -1712,10 +1712,10 @@ public static Observable generate(
*
{@code generate} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the type of the per-Subscriber state
+ * @param the type of the per-Observer state
* @param the generated value type
- * @param initialState the Callable to generate the initial state for each Subscriber
- * @param generator the Function called with the current state whenever a particular downstream Subscriber has
+ * @param initialState the Callable to generate the initial state for each Observer
+ * @param generator the Function called with the current state whenever a particular downstream Observer has
* requested a value. The callback then should call {@code onNext}, {@code onError} or
* {@code onComplete} to signal a value or a terminal event and should return a (new) state for
* the next invocation. Signalling multiple {@code onNext}
@@ -1735,10 +1735,10 @@ public static Observable generate(Callable initialState, BiFunction
*
{@code generate} does not operate by default on a particular {@link Scheduler}.
*
*
- * @param the type of the per-Subscriber state
+ * @param the type of the per-Observer state
* @param the generated value type
- * @param initialState the Callable to generate the initial state for each Subscriber
- * @param generator the Function called with the current state whenever a particular downstream Subscriber has
+ * @param initialState the Callable to generate the initial state for each Observer
+ * @param generator the Function called with the current state whenever a particular downstream Observer has
* requested a value. The callback then should call {@code onNext}, {@code onError} or
* {@code onComplete} to signal a value or a terminal event and should return a (new) state for
* the next invocation. Signalling multiple {@code onNext}
diff --git a/src/main/java/io/reactivex/Single.java b/src/main/java/io/reactivex/Single.java
index 0e455d0c2c..dd417a6509 100644
--- a/src/main/java/io/reactivex/Single.java
+++ b/src/main/java/io/reactivex/Single.java
@@ -104,6 +104,8 @@ public static Single ambArray(final SingleSource extends T>... sources)
* Concatenate the single values, in a non-overlapping fashion, of the Single sources provided by
* an Iterable sequence.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -120,19 +122,19 @@ public static Flowable concat(Iterable extends SingleSource extends T
/**
* Concatenate the single values, in a non-overlapping fashion, of the Single sources provided by
- * a Publisher sequence.
+ * an Observable sequence.
*
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
* @param the value type
- * @param sources the Publisher of SingleSource instances
- * @return the new Flowable instance
+ * @param sources the ObservableSource of SingleSource instances
+ * @return the new Observable instance
* @since 2.0
*/
@SchedulerSupport(SchedulerSupport.NONE)
@SuppressWarnings({ "unchecked", "rawtypes" })
- public static Observable concat(Observable extends SingleSource extends T>> sources) {
+ public static Observable concat(ObservableSource extends SingleSource extends T>> sources) {
return RxJavaPlugins.onAssembly(new ObservableConcatMap(sources, SingleInternalHelper.toObservable(), 2, ErrorMode.IMMEDIATE));
}
@@ -140,6 +142,9 @@ public static Observable concat(Observable extends SingleSource exten
* Concatenate the single values, in a non-overlapping fashion, of the Single sources provided by
* a Publisher sequence.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and the sources {@code Publisher} is expected to honor it as well.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -158,6 +163,9 @@ public static Flowable concat(Publisher extends SingleSource extends
* Concatenate the single values, in a non-overlapping fashion, of the Single sources provided by
* a Publisher sequence and prefetched by the specified amount.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and the sources {@code Publisher} is expected to honor it as well.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -208,6 +218,8 @@ public static Flowable concat(
*
*
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -240,6 +252,8 @@ public static Flowable concat(
*
*
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concat} does not operate by default on a particular {@link Scheduler}.
*
@@ -274,6 +288,8 @@ public static Flowable concat(
* Concatenate the single values, in a non-overlapping fashion, of the Single sources provided in
* an array.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concatArray} does not operate by default on a particular {@link Scheduler}.
{@code create} does not operate by default on a particular {@link Scheduler}.
*
* @param the value type
- * @param source the emitter that is called when a SingleObserver subscribes to the returned {@code Flowable}
+ * @param source the emitter that is called when a SingleObserver subscribes to the returned {@code Single}
* @return the new Single instance
* @see SingleOnSubscribe
* @see Cancellable
@@ -390,9 +406,9 @@ public static Single error(final Throwable exception) {
}
/**
- * Returns a {@link Single} that invokes passed function and emits its result for each new Observer that subscribes.
+ * Returns a {@link Single} that invokes passed function and emits its result for each new SingleObserver that subscribes.
*
- * Allows you to defer execution of passed function until Observer subscribes to the {@link Single}.
+ * Allows you to defer execution of passed function until SingleObserver subscribes to the {@link Single}.
* It makes passed function "lazy".
* Result of the function invocation will be emitted by the {@link Single}.
*
@@ -404,7 +420,7 @@ public static Single error(final Throwable exception) {
* function which execution should be deferred, it will be invoked when SingleObserver will subscribe to the {@link Single}.
* @param
* the type of the item emitted by the {@link Single}.
- * @return a {@link Single} whose {@link Observer}s' subscriptions trigger an invocation of the given function.
+ * @return a {@link Single} whose {@link SingleObserver}s' subscriptions trigger an invocation of the given function.
*/
@SchedulerSupport(SchedulerSupport.NONE)
public static Single fromCallable(final Callable extends T> callable) {
@@ -586,6 +602,8 @@ public static Single just(final T item) {
* Merges an Iterable sequence of SingleSource instances into a single Flowable sequence,
* running all SingleSources at once.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -604,6 +622,8 @@ public static Flowable merge(Iterable extends SingleSource extends T>
* Merges a Flowable sequence of SingleSource instances into a single Flowable sequence,
* running all SingleSources at once.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -645,13 +665,15 @@ public static Single merge(SingleSource extends SingleSource extends
}
/**
- * Flattens two Singles into a single Observable, without any transformation.
+ * Flattens two Singles into a single Flowable, without any transformation.
*
*
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by
+ * You can combine items emitted by multiple Singles so that they appear as a single Flowable, by
* using the {@code merge} method.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -676,13 +698,15 @@ public static Flowable merge(
}
/**
- * Flattens three Singles into a single Observable, without any transformation.
+ * Flattens three Singles into a single Flowable, without any transformation.
*
*
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by using
+ * You can combine items emitted by multiple Singles so that they appear as a single Flowable, by using
* the {@code merge} method.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -711,13 +735,15 @@ public static Flowable merge(
}
/**
- * Flattens four Singles into a single Observable, without any transformation.
+ * Flattens four Singles into a single Flowable, without any transformation.
*
*
*
- * You can combine items emitted by multiple Singles so that they appear as a single Observable, by using
+ * You can combine items emitted by multiple Singles so that they appear as a single Flowable, by using
* the {@code merge} method.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code merge} does not operate by default on a particular {@link Scheduler}.
*
@@ -1492,6 +1518,8 @@ public final Single cast(final Class extends U> clazz) {
*
*
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code concatWith} does not operate by default on a particular {@link Scheduler}.
*
@@ -1804,6 +1832,9 @@ public final Single flatMap(Function super T, ? extends SingleSource
*
*
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer
+ * and the {@code Publisher} returned by the mapper function is expected to honor it as well.
*
Scheduler:
*
{@code flatMapPublisher} does not operate by default on a particular {@link Scheduler}.
*
@@ -1975,6 +2006,8 @@ public final Single contains(final Object value, final BiPredicate
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code mergeWith} does not operate by default on a particular {@link Scheduler}.
*
@@ -2133,6 +2166,8 @@ public final Single onErrorResumeNext(
/**
* Repeatedly re-subscribes to the current Single and emits each success value.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code repeat} does not operate by default on a particular {@link Scheduler}.
*
@@ -2148,6 +2183,8 @@ public final Flowable repeat() {
/**
* Re-subscribes to the current Single at most the given number of times and emits each success value.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
*
Scheduler:
*
{@code repeat} does not operate by default on a particular {@link Scheduler}.
*
@@ -2166,6 +2203,9 @@ public final Flowable repeat(long times) {
* the Publisher returned by the handler function signals a value in response to a
* value signalled through the Flowable the handle receives.
*
+ *
Backpressure:
+ *
The returned {@code Flowable} honors the backpressure of the downstream consumer.
+ * The {@code Publisher} returned by the handler function is expected to honor backpressure as well.
*
Scheduler:
*
{@code repeatWhen} does not operate by default on a particular {@link Scheduler}.
*
@@ -2185,6 +2225,8 @@ public final Flowable repeatWhen(Function super Flowable