Class CancellablePublisher<T>
- java.lang.Object
-
- io.smallrye.reactive.streams.utils.CancellablePublisher<T>
-
- All Implemented Interfaces:
org.reactivestreams.Publisher<T>
public class CancellablePublisher<T> extends Object implements org.reactivestreams.Publisher<T>
Wrapped a source publisher and make it cancellable on demand. The cancellation happens if no-one subscribed to the source publisher. This class is required for theConcatStageFactoryto enforce the reactive streams rules.- Author:
- Clement Escoffier
-
-
Constructor Summary
Constructors Constructor Description CancellablePublisher(org.reactivestreams.Publisher<T> delegate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcancelIfNotSubscribed()voidsubscribe(org.reactivestreams.Subscriber<? super T> subscriber)
-
-
-
Constructor Detail
-
CancellablePublisher
public CancellablePublisher(org.reactivestreams.Publisher<T> delegate)
-
-