Example #1
0
        public void RemoveTopicBroker(string topic, string name)
        {
            TopicBrokers entry = FindTopic(topic);

            if (entry != null)
            {
                entry.RemoveBroker(name);
                if (!entry.HasBrokers())
                {
                    topicBrokers.Remove(entry);
                }
            }
        }
Example #2
0
        public void AddTopicBroker(string topic, string name, IBroker bro)
        {
            TopicBrokers entry = FindTopic(topic);

            if (entry != null)
            {
                entry.AddBroker(name, bro);
                return;
            }
            entry       = new TopicBrokers();
            entry.topic = topic;
            entry.AddBroker(name, bro);
            topicBrokers.Add(entry);
        }
Example #3
0
 public void AddTopicBroker( string topic, string name, IBroker bro )
 {
     TopicBrokers entry = FindTopic( topic );
     if ( entry != null ) {
         entry.AddBroker( name, bro );
         return;
     }
     entry = new TopicBrokers();
     entry.topic = topic;
     entry.AddBroker( name, bro );
     topicBrokers.Add( entry );
 }