src/main/java/io/reactivex/Flowable.java
@CheckReturnValue
    @NonNull
    @BackpressureSupport(BackpressureKind.PASS_THROUGH)
    @SchedulerSupport(SchedulerSupport.NONE)
    public final Flowable<T> doOnEach(final Subscriber<? super T> subscriber) {
        ObjectHelper.requireNonNull(subscriber, "subscriber is null");
        return doOnEach(
                FlowableInternalHelper.subscriberOnNext(subscriber),
                FlowableInternalHelper.subscriberOnError(subscriber),
                FlowableInternalHelper.subscriberOnComplete(subscriber),
                Functions.EMPTY_ACTION);
    }
@CheckReturnValue
    @NonNull
    @BackpressureSupport(BackpressureKind.PASS_THROUGH)
    @SchedulerSupport(SchedulerSupport.NONE)
    public final Flowable<T> doOnEach(final Subscriber<? super T> subscriber) {
        ObjectHelper.requireNonNull(subscriber, "subscriber is null");
        return doOnEach(
                FlowableInternalHelper.subscriberOnNext(subscriber),
                FlowableInternalHelper.subscriberOnError(subscriber),
                FlowableInternalHelper.subscriberOnComplete(subscriber),
                Functions.EMPTY_ACTION);
    }
@ CheckReturnValue @ NonNull @ BackpressureSupport ( BackpressureKind . PASS_THROUGH ) @ SchedulerSupport ( SchedulerSupport . NONE ) public final Flowable < T > doOnEach ( final Subscriber < ? super T > subscriber ) { ObjectHelper . requireNonNull ( subscriber , "subscriber is null" ) ; return doOnEach ( FlowableInternalHelper . subscriberOnNext ( subscriber ) , FlowableInternalHelper . subscriberOnError ( subscriber ) , FlowableInternalHelper . subscriberOnComplete ( subscriber ) , Functions . EMPTY_ACTION ) ; }
Modifies the source Publisher so that it notifies a Subscriber for each item and terminal event it emits.
<p>
In case the {@code onError} of the supplied Subscriber throws, the downstream will receive a composite
exception containing the original exception and the exception thrown by {@code onError}. If either the
{@code onNext} or the {@code onComplete} method of the supplied Subscriber throws, the downstream will be
terminated and will receive this thrown exception.
<p>
<img width="640" height="310" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/doOnEach.o.png" alt="">
<dl>
<dt><b>Backpressure:</b></dt>
<dd>The operator doesn't interfere with backpressure which is determined by the source {@code Publisher}'s
backpressure behavior.</dd>
<dt><b>Scheduler:</b></dt>
<dd>{@code doOnEach} does not operate by default on a particular {@link Scheduler}.</dd>
</dl>

@param subscriber
the Subscriber to be notified about onNext, onError and onComplete events on its
respective methods before the actual downstream Subscriber gets notified.
@return the source Publisher with the side-effecting behavior applied
@see <a href="http://reactivex.io/documentation/operators/do.html">ReactiveX operators documentation: Do</a>
Modifies the source Publisher so that it notifies a Subscriber for each item and terminal event it emits . <p > In case the { @code onError } of the supplied Subscriber throws the downstream will receive a composite exception containing the original exception and the exception thrown by { @code onError } . If either the { @code onNext } or the { @code onComplete } method of the supplied Subscriber throws the downstream will be terminated and will receive this thrown exception . <p > <img width = 640 height = 310 src = https : // raw . github . com / wiki / ReactiveX / RxJava / images / rx - operators / doOnEach . o . png alt = > <dl > <dt > <b > Backpressure : < / b > < / dt > <dd > The operator doesn t interfere with backpressure which is determined by the source { @code Publisher } s backpressure behavior . < / dd > <dt > <b > Scheduler : < / b > < / dt > <dd > { @code doOnEach } does not operate by default on a particular { @link Scheduler } . < / dd > < / dl >