예제 #1
0
        /// <summary>
        /// AddTopic adds a given topic config to the general bucket notification config
        /// </summary>
        /// <param name="topicConfig"></param>
        public void AddTopic(TopicConfig topicConfig)
        {
            bool isTopicFound = this.TopicConfigs.Exists(t => t.Topic.Equals(topicConfig));

            if (!isTopicFound)
            {
                this.TopicConfigs.Add(topicConfig);
                return;
            }
        }
예제 #2
0
        // Implement equality for this object
        public override bool Equals(Object obj)
        {
            TopicConfig other = (TopicConfig)obj;

            // If parameter is null return false.
            if (other == null)
            {
                return(false);
            }
            return(other.Topic.Equals(this.Topic));
        }