Class DefaultMessagePublisher
Inheritance
DefaultMessagePublisher
Assembly: LemonEdge.Messaging.Core.dll
Syntax
public class DefaultMessagePublisher : IMessagePublisher
Constructors
DefaultMessagePublisher()
Declaration
public DefaultMessagePublisher()
Methods
InitializeAsync(CancellationToken)
Performs all tasks required to initialize this message publisher
Declaration
public Task InitializeAsync(CancellationToken token = default)
Parameters
Returns
PublishAsync<T>(string, T, CancellationToken)
Publishes a message of type {T}
Declaration
public Task PublishAsync<T>(string topicName, T message, CancellationToken token = default) where T : class
Parameters
Type |
Name |
Description |
string |
topicName |
The topic to which the message will be published
|
T |
message |
The message to publish
|
CancellationToken |
token |
|
Returns
Type Parameters
Implements
Extension Methods