src/main/java/io/reactivex/Flowable.java
@SuppressWarnings({ "unchecked", "rawtypes" })
    @CheckReturnValue
    @NonNull
    @BackpressureSupport(BackpressureKind.FULL)
    @SchedulerSupport(SchedulerSupport.NONE)
    public static <T> Flowable<T> merge(
            Publisher<? extends T> source1, Publisher<? extends T> source2,
            Publisher<? extends T> source3, Publisher<? extends T> source4) {
        ObjectHelper.requireNonNull(source1, "source1 is null");
        ObjectHelper.requireNonNull(source2, "source2 is null");
        ObjectHelper.requireNonNull(source3, "source3 is null");
        ObjectHelper.requireNonNull(source4, "source4 is null");
        return fromArray(source1, source2, source3, source4).flatMap((Function)Functions.identity(), false, 4);
    }
@SuppressWarnings({ "unchecked", "rawtypes" })
    @CheckReturnValue
    @NonNull
    @BackpressureSupport(BackpressureKind.FULL)
    @SchedulerSupport(SchedulerSupport.NONE)
    public static <T> Flowable<T> merge(
            Publisher<? extends T> source1, Publisher<? extends T> source2,
            Publisher<? extends T> source3, Publisher<? extends T> source4) {
        ObjectHelper.requireNonNull(source1, "source1 is null");
        ObjectHelper.requireNonNull(source2, "source2 is null");
        ObjectHelper.requireNonNull(source3, "source3 is null");
        ObjectHelper.requireNonNull(source4, "source4 is null");
        return fromArray(source1, source2, source3, source4).flatMap((Function)Functions.identity(), false, 4);
    }
@ SuppressWarnings ( { "unchecked" , "rawtypes" } ) @ CheckReturnValue @ NonNull @ BackpressureSupport ( BackpressureKind . FULL ) @ SchedulerSupport ( SchedulerSupport . NONE ) public static < T > Flowable < T > merge ( Publisher < ? extends T > source1 , Publisher < ? extends T > source2 , Publisher < ? extends T > source3 , Publisher < ? extends T > source4 ) { ObjectHelper . requireNonNull ( source1 , "source1 is null" ) ; ObjectHelper . requireNonNull ( source2 , "source2 is null" ) ; ObjectHelper . requireNonNull ( source3 , "source3 is null" ) ; ObjectHelper . requireNonNull ( source4 , "source4 is null" ) ; return fromArray ( source1 , source2 , source3 , source4 ) . flatMap ( ( Function ) Functions . identity ( ) , false , 4 ) ; }
Flattens four Publishers into a single Publisher, without any transformation.
<p>
<img width="640" height="380" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/merge.png" alt="">
<p>
You can combine items emitted by multiple Publishers so that they appear as a single Publisher, by
using the {@code merge} method.
<dl>
<dt><b>Backpressure:</b></dt>
<dd>The operator honors backpressure from downstream. The source {@code Publisher}s are expected to honor
backpressure; if violated, the operator <em>may</em> signal {@code MissingBackpressureException}.</dd>
<dt><b>Scheduler:</b></dt>
<dd>{@code merge} does not operate by default on a particular {@link Scheduler}.</dd>
<dt><b>Error handling:</b></dt>
<dd>If any of the source {@code Publisher}s signal a {@code Throwable} via {@code onError}, the resulting
{@code Flowable} terminates with that {@code Throwable} and all other source {@code Publisher}s are canceled.
If more than one {@code Publisher} signals an error, the resulting {@code Flowable} may terminate with the
first one's error or, depending on the concurrency of the sources, may terminate with a
{@code CompositeException} containing two or more of the various error signals.
{@code Throwable}s that didn't make into the composite will be sent (individually) to the global error handler via
{@link RxJavaPlugins#onError(Throwable)} method as {@code UndeliverableException} errors. Similarly, {@code Throwable}s
signaled by source(s) after the returned {@code Flowable} has been canceled or terminated with a
(composite) error will be sent to the same global error handler.
Use {@link #mergeDelayError(Publisher, Publisher, Publisher, Publisher)} to merge sources and terminate only when all source {@code Publisher}s
have completed or failed with an error.
</dd>
</dl>

@param <T> the common element base type
@param source1
a Publisher to be merged
@param source2
a Publisher to be merged
@param source3
a Publisher to be merged
@param source4
a Publisher to be merged
@return a Flowable that emits all of the items emitted by the source Publishers
@see <a href="http://reactivex.io/documentation/operators/merge.html">ReactiveX operators documentation: Merge</a>
@see #mergeDelayError(Publisher, Publisher, Publisher, Publisher)
Flattens four Publishers into a single Publisher without any transformation . <p > <img width = 640 height = 380 src = https : // raw . github . com / wiki / ReactiveX / RxJava / images / rx - operators / merge . png alt = > <p > You can combine items emitted by multiple Publishers so that they appear as a single Publisher by using the { @code merge } method . <dl > <dt > <b > Backpressure : < / b > < / dt > <dd > The operator honors backpressure from downstream . The source { @code Publisher } s are expected to honor backpressure ; if violated the operator <em > may< / em > signal { @code MissingBackpressureException } . < / dd > <dt > <b > Scheduler : < / b > < / dt > <dd > { @code merge } does not operate by default on a particular { @link Scheduler } . < / dd > <dt > <b > Error handling : < / b > < / dt > <dd > If any of the source { @code Publisher } s signal a { @code Throwable } via { @code onError } the resulting { @code Flowable } terminates with that { @code Throwable } and all other source { @code Publisher } s are canceled . If more than one { @code Publisher } signals an error the resulting { @code Flowable } may terminate with the first one s error or depending on the concurrency of the sources may terminate with a { @code CompositeException } containing two or more of the various error signals . { @code Throwable } s that didn t make into the composite will be sent ( individually ) to the global error handler via { @link RxJavaPlugins#onError ( Throwable ) } method as { @code UndeliverableException } errors . Similarly { @code Throwable } s signaled by source ( s ) after the returned { @code Flowable } has been canceled or terminated with a ( composite ) error will be sent to the same global error handler . Use { @link #mergeDelayError ( Publisher Publisher Publisher Publisher ) } to merge sources and terminate only when all source { @code Publisher } s have completed or failed with an error . < / dd > < / dl >