@Test public void test0() { AsyncCountDownLatch latch = new AsyncCountDownLatch(0); MyObserver subscriber = new MyObserver(); latch.subscribe(subscriber); Assert.assertFalse(subscriber.onSubscribeSeen.get()); Assert.assertTrue(subscriber.onCompleteSeen.get()); }
@Override public void subscribe(Completable.Observer subscriber) { completionSignal.subscribe(subscriber); }
AsyncCountDownLatch extends CountDownLatch implements Completable.Source { @Override public void subscribe(Completable.Observer subscriber) { completionSignal.subscribe(subscriber); } }
AsyncCountDownLatch extends CountDownLatch implements Completable.Source { @Override public void subscribe(Completable.Observer subscriber) { completionSignal.subscribe(subscriber); } AsyncCountDownLatch(int count); }
AsyncCountDownLatch extends CountDownLatch implements Completable.Source { @Override public void subscribe(Completable.Observer subscriber) { completionSignal.subscribe(subscriber); } AsyncCountDownLatch(int count); boolean isCompleted(); @Override void subscribe(Completable.Observer subscriber); void countDown(); }
AsyncCountDownLatch extends CountDownLatch implements Completable.Source { @Override public void subscribe(Completable.Observer subscriber) { completionSignal.subscribe(subscriber); } AsyncCountDownLatch(int count); boolean isCompleted(); @Override void subscribe(Completable.Observer subscriber); void countDown();  }