1
0
mirror of synced 2024-06-29 07:17:39 +00:00
Tapeti/Tapeti/IPublisher.cs

20 lines
621 B
C#

using System.Threading.Tasks;
using RabbitMQ.Client;
namespace Tapeti
{
// Note: Tapeti assumes every implementation of IPublisher can also be cast to an IInternalPublisher.
// The distinction is made on purpose to trigger code-smells in non-Tapeti code when casting.
public interface IPublisher
{
Task Publish(object message);
}
public interface IInternalPublisher : IPublisher
{
Task Publish(object message, IBasicProperties properties, bool mandatory);
Task PublishDirect(object message, string queueName, IBasicProperties properties, bool mandatory);
}
}