Class SubscribableSingle<T>
java.lang.Object
io.servicetalk.concurrent.api.Single<T>
io.servicetalk.concurrent.api.internal.SubscribableSingle<T>
- Type Parameters:
T
- Type of result of thisSubscribableSingle
.
- All Implemented Interfaces:
SingleSource<T>
- Direct Known Subclasses:
SourceWrappers.SingleSource
A
Single
that is also a SingleSource
and hence can be subscribed.
Typically, this will be used to implement a Single
that does not require an additional allocation when
converting to a SingleSource
via SourceAdapters.toSource(Single)
.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.servicetalk.concurrent.SingleSource
SingleSource.Processor<T,
R>, SingleSource.Subscriber<T> -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionfinal void
subscribe
(SingleSource.Subscriber<? super T> subscriber) Subscribe for the result of thisSingleSource
.Methods inherited from class io.servicetalk.concurrent.api.Single
afterCancel, afterFinally, afterFinally, afterFinally, afterOnError, afterOnSubscribe, afterOnSuccess, afterSubscriber, amb, amb, ambWith, anyOf, anyOf, beforeCancel, beforeFinally, beforeFinally, beforeFinally, beforeOnError, beforeOnSubscribe, beforeOnSuccess, beforeSubscriber, cache, cache, cache, cache, cast, collectUnordered, collectUnordered, collectUnordered, collectUnordered, collectUnorderedDelayError, collectUnorderedDelayError, collectUnorderedDelayError, collectUnorderedDelayError, concat, concat, concat, concat, concatDeferSubscribe, concatPropagateCancel, defer, failed, flatMap, flatMapCompletable, flatMapPublisher, fromCallable, fromFuture, fromStage, fromSupplier, handleSubscribe, ignoreElement, liftAsync, liftSync, map, never, onErrorMap, onErrorMap, onErrorMap, onErrorResume, onErrorResume, onErrorResume, onErrorReturn, onErrorReturn, onErrorReturn, publishOn, publishOn, repeat, repeat, repeatWhen, repeatWhen, retry, retryWhen, setContextOnSubscribe, shareContextOnSubscribe, subscribe, subscribeInternal, subscribeOn, subscribeOn, succeeded, timeout, timeout, timeout, timeout, toCompletable, toCompletionStage, toFuture, toPublisher, whenCancel, whenFinally, whenFinally, whenFinally, whenOnError, whenOnSubscribe, whenOnSuccess, whenSubscriber, zip, zip, zip, zip, zipDelayError, zipDelayError, zipDelayError, zipDelayError, zipWith, zipWithDelayError
-
Constructor Details
-
SubscribableSingle
public SubscribableSingle()
-
-
Method Details
-
subscribe
Description copied from interface:SingleSource
Subscribe for the result of thisSingleSource
.- Specified by:
subscribe
in interfaceSingleSource<T>
- Parameters:
subscriber
- to subscribe for the result.- See Also:
-