예제 #1
0
        /// <summary>
        /// Fills the node category
        /// </summary>
        private void FillCategory()
        {
            ConfigCategory cat;

            foreach (XElement catNode in this.App_Node.Data.Elements())
            {
                cat = new ConfigCategory(catNode.Name.ToString(), this.App_Node);
                this.Add(cat);
            }
        }
예제 #2
0
 /// <summary>
 /// Adds a new category
 /// </summary>
 /// <param name="item">The category to be added</param>
 public void Add(ConfigCategory item)
 {
     this.categories.Add(item.Name, item);
 }
예제 #3
0
 /// <summary>
 /// Check if a category is already defined
 /// </summary>
 /// <param name="item">The configuration category to be tested</param>
 /// <returns>True if the configuration category is contained</returns>
 public bool Contains(ConfigCategory item)
 {
     return(this.categories.ContainsKey(item.Name));
 }
예제 #4
0
        /// <summary>
        /// Adds a new category
        /// </summary>
        /// <param name="item">The category to be added</param>
        public void Add(String catName)
        {
            ConfigCategory item = new ConfigCategory(catName, this.App_Node);

            this.categories.Add(catName, item);
        }