@Test public void testSynchronousNext() { assertEquals(1, BehaviorSubject.create(1).take(1).toBlocking().single().intValue()); assertEquals(2, BehaviorSubject.create(2).toBlocking().toIterable().iterator().next().intValue()); assertEquals(3, BehaviorSubject.create(3).toBlocking().next().iterator().next().intValue()); }
public static <T> Iterable<T> next(final Observable<? extends T> items) { return new Iterable<T>() { @Override public Iterator<T> iterator() { NextObserver<T> nextObserver = new NextObserver<T>(); return new NextIterator<T>(items, nextObserver); } }; }
BlockingOperatorNext { public static <T> Iterable<T> next(final Observable<? extends T> items) { return new Iterable<T>() { @Override public Iterator<T> iterator() { NextObserver<T> nextObserver = new NextObserver<T>(); return new NextIterator<T>(items, nextObserver); } }; } }
BlockingOperatorNext { public static <T> Iterable<T> next(final Observable<? extends T> items) { return new Iterable<T>() { @Override public Iterator<T> iterator() { NextObserver<T> nextObserver = new NextObserver<T>(); return new NextIterator<T>(items, nextObserver); } }; } private  BlockingOperatorNext(); }
BlockingOperatorNext { public static <T> Iterable<T> next(final Observable<? extends T> items) { return new Iterable<T>() { @Override public Iterator<T> iterator() { NextObserver<T> nextObserver = new NextObserver<T>(); return new NextIterator<T>(items, nextObserver); } }; } private  BlockingOperatorNext(); static Iterable<T> next(final Observable<? extends T> items); }
BlockingOperatorNext { public static <T> Iterable<T> next(final Observable<? extends T> items) { return new Iterable<T>() { @Override public Iterator<T> iterator() { NextObserver<T> nextObserver = new NextObserver<T>(); return new NextIterator<T>(items, nextObserver); } }; } private  BlockingOperatorNext(); static Iterable<T> next(final Observable<? extends T> items);  }