src/main/java/io/reactivex/Observable.java
@CheckReturnValue
    @SchedulerSupport(SchedulerSupport.NONE)
    public final <U, R> Observable<R> flatMap(Function<? super T, ? extends ObservableSource<? extends U>> mapper,
            BiFunction<? super T, ? super U, ? extends R> resultSelector) {
        return flatMap(mapper, resultSelector, false, bufferSize(), bufferSize());
    }
@CheckReturnValue
    @SchedulerSupport(SchedulerSupport.NONE)
    public final <U, R> Observable<R> flatMap(Function<? super T, ? extends ObservableSource<? extends U>> mapper,
            BiFunction<? super T, ? super U, ? extends R> resultSelector) {
        return flatMap(mapper, resultSelector, false, bufferSize(), bufferSize());
    }
Returns an Observable that emits the results of a specified function to the pair of values emitted by the
source ObservableSource and a specified collection ObservableSource.
<p>
<img width="640" height="390" src="https://raw.github.com/wiki/ReactiveX/RxJava/images/rx-operators/mergeMap.r.png" alt="">
<dl>
<dt><b>Scheduler:</b></dt>
<dd>{@code flatMap} does not operate by default on a particular {@link Scheduler}.</dd>
</dl>

@param <U>
the type of items emitted by the collection ObservableSource
@param <R>
the type of items emitted by the resulting ObservableSource
@param mapper
a function that returns an ObservableSource for each item emitted by the source ObservableSource
@param resultSelector
a function that combines one item emitted by each of the source and collection ObservableSources and
returns an item to be emitted by the resulting ObservableSource
@return an Observable that emits the results of applying a function to a pair of values emitted by the
source ObservableSource and the collection ObservableSource
@see <a href="http://reactivex.io/documentation/operators/flatmap.html">ReactiveX operators documentation: FlatMap</a>