public Mood(MoodCategory category, string name, MoodType moodType, string displayColor, int displayIndex) : this() { this.Category = category; this.Name = name; this.DisplayColor = displayColor; this.DisplayIndex = displayIndex; this.MoodType = moodType; }
public MoodCategory AddCategory(string name) { var cat = this.MoodCategoriesCollection.FirstOrDefault(c => c.Name.Equals(name, StringComparison.InvariantCultureIgnoreCase)); if (cat == null) { cat = new MoodCategory(this, name); this.MoodCategoriesCollection.Add(cat); } return(cat); }