using System;
using JetBrains.Annotations;
namespace Tapeti.Annotations
{
///
///
/// Creates a non-durable auto-delete queue to receive messages. Can be used
/// on an entire MessageController class or on individual methods.
///
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Method)]
[MeansImplicitUse]
public class DynamicQueueAttribute : Attribute
{
///
/// An optional prefix. If specified, Tapeti will compose the queue name using the
/// prefix and a unique ID. If not specified, an empty queue name will be passed
/// to RabbitMQ thus letting it create a unique queue name.
///
public string Prefix { get; set; }
///
/// An optional prefix. If specified, Tapeti will compose the queue name using the
/// prefix and a unique ID. If not specified, an empty queue name will be passed
/// to RabbitMQ thus letting it create a unique queue name.
public DynamicQueueAttribute(string prefix = null)
{
Prefix = prefix;
}
}
}