Beispiel #1
0
 public bool Equals(SubscriptionKey other)
 {
     if (ReferenceEquals(null, other))
     {
         return(false);
     }
     if (ReferenceEquals(this, other))
     {
         return(true);
     }
     return(Equals(other._messageType, _messageType) && Equals(other._routingKey, _routingKey) && Equals(other._arguments, _arguments));
 }
Beispiel #2
0
        void UnsubscribeMessage <TMessage>(MessageProperties messageProperties)
        {
            ISubscription subscription;
            var           key = new SubscriptionKey(typeof(TMessage), messageProperties);

            _subscriptions.TryGetValue(key, out subscription);

            if (subscription != null)
            {
                subscription.Stop();
                _subscriptions.Remove(key);
            }
        }
Beispiel #3
0
        void UnsubscribeMessage <TMessage>(string routingKey, IDictionary headers)
        {
            ISubscription subscription;
            var           key = new SubscriptionKey(typeof(TMessage), routingKey, headers);

            _subscriptions.TryGetValue(key, out subscription);

            if (subscription != null)
            {
                subscription.Stop();
                _subscriptions.Remove(key);
            }
        }
		public bool Equals(SubscriptionKey other)
		{
			if (ReferenceEquals(null, other)) return false;
			if (ReferenceEquals(this, other)) return true;
			return Equals(other._messageType, _messageType) && Equals(other._routingKey, _routingKey) && Equals(other._arguments, _arguments);
		}
Beispiel #5
0
		protected bool Equals(SubscriptionKey other)
		{
			return Equals(_messageType, other._messageType) && Equals(_messageProperties, other._messageProperties);
		}
Beispiel #6
0
 protected bool Equals(SubscriptionKey other)
 {
     return(Equals(_messageType, other._messageType) && Equals(_messageProperties, other._messageProperties));
 }