Ejemplo n.º 1
0
 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;
 }
Ejemplo n.º 2
0
        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);
        }