Package io.servicetalk.concurrent
Interface SingleSource<T>
- Type Parameters:
T- Type of the result of thisSingleSource.
- All Known Subinterfaces:
SingleSource.Processor<T,R>
- All Known Implementing Classes:
SourceWrappers.SingleSource,SubscribableSingle
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
An asynchronous computation that either completes with success giving the result or completes with an error.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic interfaceASingleSource.Processorrepresents a processing stage that is both aSingleSourceand aSingleSource.Subscriberand obeys the contracts of both.static interfaceSubscriber of the outcome of aSingleSource. -
Method Summary
Modifier and TypeMethodDescriptionvoidsubscribe(SingleSource.Subscriber<? super T> subscriber) Subscribe for the result of thisSingleSource.
-
Method Details
-
subscribe
Subscribe for the result of thisSingleSource.- Parameters:
subscriber- to subscribe for the result.- See Also:
-