Class SubscriberWhiteboxVerification.BlackboxSubscriberProxy<T>
java.lang.Object
org.reactivestreams.tck.SubscriberWhiteboxVerification.BlackboxProbe<T>
org.reactivestreams.tck.SubscriberWhiteboxVerification.BlackboxSubscriberProxy<T>
- All Implemented Interfaces:
Subscriber<T>, SubscriberWhiteboxVerification.SubscriberProbe<T>
- Enclosing class:
SubscriberWhiteboxVerification<T>
public static class SubscriberWhiteboxVerification.BlackboxSubscriberProxy<T>
extends SubscriberWhiteboxVerification.BlackboxProbe<T>
implements Subscriber<T>
This class is intented to be used as
Subscriber decorator and should be used in pub.subscriber(...) calls,
in order to allow intercepting calls on the underlying Subscriber.
This delegation allows the proxy to implement SubscriberWhiteboxVerification.BlackboxProbe assertions.-
Field Summary
Fields inherited from class SubscriberWhiteboxVerification.BlackboxProbe
elements, env, error, subscriber -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidSuccessful terminal state.voidFailed terminal state.voidData notification sent by thePublisherin response to requests toSubscription.request(long).voidInvoked after callingPublisher.subscribe(Subscriber).Methods inherited from class SubscriberWhiteboxVerification.BlackboxProbe
expectCompletion, expectCompletion, expectCompletion, expectError, expectError, expectError, expectError, expectErrorWithMessage, expectNext, expectNext, expectNext, expectNone, expectNone, registerOnComplete, registerOnError, registerOnNext, sub
-
Constructor Details
-
BlackboxSubscriberProxy
-
-
Method Details
-
onSubscribe
Description copied from interface:SubscriberInvoked after callingPublisher.subscribe(Subscriber).No data will start flowing until
Subscription.request(long)is invoked.It is the responsibility of this
Subscriberinstance to callSubscription.request(long)whenever more data is wanted.The
Publisherwill send notifications only in response toSubscription.request(long).- Specified by:
onSubscribein interfaceSubscriber<T>- Parameters:
s- theSubscriptionthat allows requesting data viaSubscription.request(long)
-
onNext
Description copied from interface:SubscriberData notification sent by thePublisherin response to requests toSubscription.request(long).- Specified by:
onNextin interfaceSubscriber<T>- Parameters:
t- the element signaled
-
onError
Description copied from interface:SubscriberFailed terminal state.No further events will be sent even if
Subscription.request(long)is invoked again.- Specified by:
onErrorin interfaceSubscriber<T>- Parameters:
cause- the throwable signaled
-
onComplete
public void onComplete()Description copied from interface:SubscriberSuccessful terminal state.No further events will be sent even if
Subscription.request(long)is invoked again.- Specified by:
onCompletein interfaceSubscriber<T>
-