Skip to main content

IRedisSubscriptionAsync

Assembly: ServiceStack.Interfaces.dll
View Source
Declaration
public interface IRedisSubscriptionAsync

Properties

SubscriptionCount

The number of active subscriptions this client has

View Source
Declaration
long SubscriptionCount { get; }

Methods

SubscribeToChannelsAsync(String[], CancellationToken)

Subscribe to channels by name

View Source
Declaration
ValueTask SubscribeToChannelsAsync(string[] channels, CancellationToken token = default(CancellationToken))
Returns

ValueTask

Parameters
TypeName
System.String[]channels
System.Threading.CancellationTokentoken

SubscribeToChannelsAsync(String[])

Subscribe to channels by name

View Source
Declaration
ValueTask SubscribeToChannelsAsync(params string[] channels)
Returns

ValueTask

Parameters
TypeName
System.String[]channels

SubscribeToChannelsMatchingAsync(String[], CancellationToken)

Subscribe to channels matching the supplied patterns

View Source
Declaration
ValueTask SubscribeToChannelsMatchingAsync(string[] patterns, CancellationToken token = default(CancellationToken))
Returns

ValueTask

Parameters
TypeName
System.String[]patterns
System.Threading.CancellationTokentoken

SubscribeToChannelsMatchingAsync(String[])

Subscribe to channels matching the supplied patterns

View Source
Declaration
ValueTask SubscribeToChannelsMatchingAsync(params string[] patterns)
Returns

ValueTask

Parameters
TypeName
System.String[]patterns

UnSubscribeFromAllChannelsAsync(CancellationToken)

View Source
Declaration
ValueTask UnSubscribeFromAllChannelsAsync(CancellationToken token = default(CancellationToken))
Returns

ValueTask

Parameters
TypeName
System.Threading.CancellationTokentoken

UnSubscribeFromChannelsAsync(String[], CancellationToken)

View Source
Declaration
ValueTask UnSubscribeFromChannelsAsync(string[] channels, CancellationToken token = default(CancellationToken))
Returns

ValueTask

Parameters
TypeName
System.String[]channels
System.Threading.CancellationTokentoken

UnSubscribeFromChannelsAsync(String[])

View Source
Declaration
ValueTask UnSubscribeFromChannelsAsync(params string[] channels)
Returns

ValueTask

Parameters
TypeName
System.String[]channels

UnSubscribeFromChannelsMatchingAsync(String[], CancellationToken)

View Source
Declaration
ValueTask UnSubscribeFromChannelsMatchingAsync(string[] patterns, CancellationToken token = default(CancellationToken))
Returns

ValueTask

Parameters
TypeName
System.String[]patterns
System.Threading.CancellationTokentoken

UnSubscribeFromChannelsMatchingAsync(String[])

View Source
Declaration
ValueTask UnSubscribeFromChannelsMatchingAsync(params string[] patterns)
Returns

ValueTask

Parameters
TypeName
System.String[]patterns

Events

OnSubscribeAsync

Registered handler called after client Subscribes to each new channel

View Source
Declaration
event Func<string, ValueTask> OnSubscribeAsync
Event Type

System.Func<System.String,ValueTask>

OnMessageAsync

Registered handler called when each message is received

View Source
Declaration
event Func<string, string, ValueTask> OnMessageAsync
Event Type

System.Func<System.String,System.String,ValueTask>

OnMessageBytesAsync

Registered handler called when each message is received

View Source
Declaration
event Func<string, byte[], ValueTask> OnMessageBytesAsync
Event Type

System.Func<System.String,System.Byte[],ValueTask>

OnUnSubscribeAsync

Registered handler called when each channel is unsubscribed

View Source
Declaration
event Func<string, ValueTask> OnUnSubscribeAsync
Event Type

System.Func<System.String,ValueTask>