Edit

Share via


IAsyncBatchObservable<T>.SubscribeAsync Method

Definition

Overloads

SubscribeAsync(IAsyncBatchObserver<T>)

Subscribe a consumer to this batch observable.

SubscribeAsync(IAsyncBatchObserver<T>, StreamSequenceToken)

Subscribe a consumer to this batch observable.

SubscribeAsync(IAsyncBatchObserver<T>)

Source:
IAsyncBatchObservable.cs

Subscribe a consumer to this batch observable.

public System.Threading.Tasks.Task<Orleans.Streams.StreamSubscriptionHandle<T>> SubscribeAsync (Orleans.Streams.IAsyncBatchObserver<T> observer);
abstract member SubscribeAsync : Orleans.Streams.IAsyncBatchObserver<'T> -> System.Threading.Tasks.Task<Orleans.Streams.StreamSubscriptionHandle<'T>>
Public Function SubscribeAsync (observer As IAsyncBatchObserver(Of T)) As Task(Of StreamSubscriptionHandle(Of T))

Parameters

observer
IAsyncBatchObserver<T>

The asynchronous batch observer to subscribe.

Returns

A promise for a StreamSubscriptionHandle that represents the subscription. The consumer may unsubscribe by using this handle. The subscription remains active for as long as it is not explicitly unsubscribed.

Applies to

SubscribeAsync(IAsyncBatchObserver<T>, StreamSequenceToken)

Source:
IAsyncBatchObservable.cs

Subscribe a consumer to this batch observable.

public System.Threading.Tasks.Task<Orleans.Streams.StreamSubscriptionHandle<T>> SubscribeAsync (Orleans.Streams.IAsyncBatchObserver<T> observer, Orleans.Streams.StreamSequenceToken token);
public System.Threading.Tasks.Task<Orleans.Streams.StreamSubscriptionHandle<T>> SubscribeAsync (Orleans.Streams.IAsyncBatchObserver<T> observer, Orleans.Streams.StreamSequenceToken? token);
abstract member SubscribeAsync : Orleans.Streams.IAsyncBatchObserver<'T> * Orleans.Streams.StreamSequenceToken -> System.Threading.Tasks.Task<Orleans.Streams.StreamSubscriptionHandle<'T>>
Public Function SubscribeAsync (observer As IAsyncBatchObserver(Of T), token As StreamSequenceToken) As Task(Of StreamSubscriptionHandle(Of T))

Parameters

observer
IAsyncBatchObserver<T>

The asynchronous batch observer to subscribe.

token
StreamSequenceToken

The stream sequence to be used as an offset to start the subscription from.

Returns

A promise for a StreamSubscriptionHandle that represents the subscription. The consumer may unsubscribe by using this handle. The subscription remains active for as long as it is not explicitly unsubscribed.

Applies to