5151 * Finally the actions scheduled on the parent {@link Scheduler} when the inner
5252 * most {@link Completable}s are subscribed to.
5353 * <p>
54- * When the {@link Worker} is unsubscribed the {@link Completable} emits an
54+ * When the {@link io.reactivex.Scheduler.Worker Worker} is unsubscribed the {@link Completable} emits an
5555 * onComplete and triggers any behavior in the flattening operator. The
5656 * {@link Observable} and all {@link Completable}s give to the flattening
5757 * function never onError.
6969 * <p>
7070 * This is a slightly different way to limit the concurrency but it has some
7171 * interesting benefits and drawbacks to the method above. It works by limited
72- * the number of concurrent {@link Worker}s rather than individual actions.
73- * Generally each {@link Observable} uses its own {@link Worker}. This means
72+ * the number of concurrent {@link io.reactivex.Scheduler.Worker Worker}s rather than individual actions.
73+ * Generally each {@link Observable} uses its own {@link io.reactivex.Scheduler.Worker Worker}. This means
7474 * that this will essentially limit the number of concurrent subscribes. The
7575 * danger comes from using operators like
76- * {@link Observable #zip(Observable, Observable, rx. functions.Func2 )} where
76+ * {@link Flowable #zip(org.reactivestreams.Publisher, org.reactivestreams.Publisher, io.reactivex. functions.BiFunction )} where
7777 * subscribing to the first {@link Observable} could deadlock the subscription
7878 * to the second.
7979 *
9999 * }));
100100 * });
101101 * </pre>
102- *
103- * @param combine
104- * @return
105102 */
106103@ Experimental
107104public class SchedulerWhen extends Scheduler implements Disposable {
@@ -209,12 +206,12 @@ public boolean isDisposed() {
209206 static final Disposable DISPOSED = Disposables .disposed ();
210207
211208 @ SuppressWarnings ("serial" )
212- static abstract class ScheduledAction extends AtomicReference <Disposable >implements Disposable {
213- public ScheduledAction () {
209+ abstract static class ScheduledAction extends AtomicReference <Disposable >implements Disposable {
210+ ScheduledAction () {
214211 super (SUBSCRIBED );
215212 }
216213
217- private final void call (Worker actualWorker , CompletableObserver actionCompletable ) {
214+ void call (Worker actualWorker , CompletableObserver actionCompletable ) {
218215 Disposable oldState = get ();
219216 // either SUBSCRIBED or UNSUBSCRIBED
220217 if (oldState == DISPOSED ) {
@@ -270,7 +267,7 @@ public void dispose() {
270267 static class ImmediateAction extends ScheduledAction {
271268 private final Runnable action ;
272269
273- public ImmediateAction (Runnable action ) {
270+ ImmediateAction (Runnable action ) {
274271 this .action = action ;
275272 }
276273
@@ -286,7 +283,7 @@ static class DelayedAction extends ScheduledAction {
286283 private final long delayTime ;
287284 private final TimeUnit unit ;
288285
289- public DelayedAction (Runnable action , long delayTime , TimeUnit unit ) {
286+ DelayedAction (Runnable action , long delayTime , TimeUnit unit ) {
290287 this .action = action ;
291288 this .delayTime = delayTime ;
292289 this .unit = unit ;
@@ -302,7 +299,7 @@ static class OnCompletedAction implements Runnable {
302299 private CompletableObserver actionCompletable ;
303300 private Runnable action ;
304301
305- public OnCompletedAction (Runnable action , CompletableObserver actionCompletable ) {
302+ OnCompletedAction (Runnable action , CompletableObserver actionCompletable ) {
306303 this .action = action ;
307304 this .actionCompletable = actionCompletable ;
308305 }
0 commit comments