BotSharp/src/Infrastructure/BotSharp.Abstraction/Infrastructures/Events/IEventPublisher.cs
2024-11-23 14:48:22 +00:00

19 lines
587 B
C#

namespace BotSharp.Abstraction.Infrastructures.Events;
public interface IEventPublisher
{
/// <summary>
/// Boardcast message to all subscribers
/// </summary>
/// <param name="channel"></param>
/// <param name="message"></param>
/// <returns></returns>
Task BroadcastAsync(string channel, string message);
Task PublishAsync(string channel, string message, EventPriority? priority = null);
Task ReDispatchAsync(string channel, int count = 10, string order = "asc");
Task ReDispatchPendingAsync(string channel, string group, int count = 10);
}