Class CompletionStageMappingPublisher.CompletionStageSubscriber
java.lang.Object
graphql.execution.reactive.CompletionStageMappingPublisher.CompletionStageSubscriber
- All Implemented Interfaces:
org.reactivestreams.Subscriber<U>
- Enclosing class:
CompletionStageMappingPublisher<D,U>
public class CompletionStageMappingPublisher.CompletionStageSubscriber
extends Object
implements org.reactivestreams.Subscriber<U>
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) org.reactivestreams.Subscriptionprivate final org.reactivestreams.Subscriber<? super D> (package private) final Queue<CompletionStage<?>> (package private) final LockKit.ReentrantLock(package private) final AtomicReference<Runnable> (package private) final AtomicBoolean -
Constructor Summary
ConstructorsConstructorDescriptionCompletionStageSubscriber(org.reactivestreams.Subscriber<? super D> downstreamSubscriber) -
Method Summary
Modifier and TypeMethodDescriptionorg.reactivestreams.Subscriber<? super D> Get instance of downstream subscriberprivate voidhandleThrowable(Throwable throwable) private booleanprivate voidofferToInFlightQ(CompletionStage<?> completionStage) voidprivate voidonCompleteOrError(Runnable doneCodeToRun) voidvoidvoidonSubscribe(org.reactivestreams.Subscription subscription) private booleanremoveFromInFlightQAndCheckIfEmpty(CompletionStage<?> completionStage) private BiConsumer<D, Throwable> whenNextFinished(CompletionStage<D> completionStage)
-
Field Details
-
downstreamSubscriber
-
delegatingSubscription
org.reactivestreams.Subscription delegatingSubscription -
inFlightDataQ
-
lock
-
onCompleteOrErrorRun
-
onCompleteOrErrorRunCalled
-
-
Constructor Details
-
CompletionStageSubscriber
-
-
Method Details
-
onSubscribe
public void onSubscribe(org.reactivestreams.Subscription subscription) - Specified by:
onSubscribein interfaceorg.reactivestreams.Subscriber<U>
-
onNext
-
whenNextFinished
-
handleThrowable
-
onError
-
onComplete
public void onComplete()- Specified by:
onCompletein interfaceorg.reactivestreams.Subscriber<U>
-
getDownstreamSubscriber
Get instance of downstream subscriber- Returns:
Subscriber
-
onCompleteOrError
-
offerToInFlightQ
-
removeFromInFlightQAndCheckIfEmpty
-
inFlightQIsEmpty
private boolean inFlightQIsEmpty()
-