public void Update(IWheatherData wheatherData) { MaxTemperature = Math.Max(MaxTemperature, wheatherData.Temperature); MinTemperature = Math.Min(MinTemperature, wheatherData.Temperature); MaxHumidity = Math.Max(MaxHumidity, wheatherData.Humidity); MinHumidity = Math.Min(MinHumidity, wheatherData.Humidity); MaxPressure = Math.Max(MaxPressure, wheatherData.Pressure); MinPressure = Math.Min(MinPressure, wheatherData.Pressure); Display(); }
public void Update(IWheatherData wheatherData) { CurrentWheatherData = wheatherData; Display(); }
public WheatherDataEventArgs(IWheatherData newWheatherData) { CurrentWheatherData = newWheatherData; }
public void Update(IWheatherData wheatherData) { HeatIndex = 16.92f + 1.85f * wheatherData.Temperature + 5.38f * wheatherData.Humidity - wheatherData.Temperature * wheatherData.Humidity; Display(); }