public ClothingItem(int id, string name, ClothingType clothingType, Weather weather) { Id = id; Name = name; ClothingType = clothingType; Weather = weather; }
protected bool Equals(Weather other) { return WeatherCondition == other.WeatherCondition && Temperature == other.Temperature; }
public IEnumerable<ClothingItem> GetClothingFor(Weather weather) { return clothingItemList.Values.Where(p => p.Weather.Equals(weather)); }
// GET api/values/5 public IEnumerable<ClothingItem> GetWardRobeByWeather(Weather weather) { return wardRobe.GetClothingFor(weather); }