xxxxxxxxxx
class MergeAndConcat {
public static void main(String[] args) throws InterruptedException {
Observable<String> src1 = Observable.interval(1, TimeUnit.SECONDS).map(e -> "src1 : "+e);
Observable<String> src2 = Observable.interval(1, TimeUnit.SECONDS).map(e -> "src2 : "+e);
src1.concatWith(src2)
.subscribe(e -> System.out.println("Received : "+ e));
Thread.sleep(20000);
}
}