예제 #1
0
        public QueueBindingHandle QueueBind(ExchangeHandle exchange, QueueHandle queue, string routingKey, IDictionary <string, object> arguments)
        {
            var id = GetNextId();

            var exchangeEntity = Exchanges.Get(exchange);

            var queueEntity = Queues.Get(queue);

            var binding = new QueueBindingEntity(id, exchangeEntity, queueEntity, routingKey, arguments);

            return(QueueBindings.GetOrAdd(binding));
        }
예제 #2
0
        public ExchangeBindingHandle ExchangeBind(ExchangeHandle source, ExchangeHandle destination, string routingKey, IDictionary <string, object> arguments)
        {
            var id = GetNextId();

            var sourceExchange = Exchanges.Get(source);

            var destinationExchange = Exchanges.Get(destination);

            var binding = new ExchangeBindingEntity(id, sourceExchange, destinationExchange, routingKey, arguments);

            return(ExchangeBindings.GetOrAdd(binding));
        }
 public ExchangeBindingHandle ExchangeBind(ExchangeHandle source, ExchangeHandle destination, string routingKey,
                                           IDictionary <string, object> arguments)
 {
     return(_builder.ExchangeBind(source, destination, routingKey, arguments));
 }
 public QueueBindingHandle QueueBind(ExchangeHandle exchange, QueueHandle queue, string routingKey, IDictionary <string, object> arguments)
 {
     return(_builder.QueueBind(exchange, queue, routingKey, arguments));
 }