Exemplo n.º 1
0
        /// <summary>
        /// Checks if this category equalses to the specified category.
        /// </summary>
        /// <param name="category">The category to compare to.</param>
        /// <returns></returns>
        public bool Equals(Category category)
        {
            if (category == null)
                return false;

            return (this.Id == category.Id && this.Converted == category.Converted);
        }
Exemplo n.º 2
0
 /// <summary>
 /// Gets all categories.
 /// </summary>
 /// <returns></returns>
 public static List<Category> GetCategories()
 {
     List<Category> categories = new List<Category>();
     Category mother = new Category();
     for (int i = 0; i < mother.CategoryNames.Length; i++)
         categories.Add(new Category(i));
     return categories;
 }