public ObserverWeatherDataUnitTest() { _weatherData = new WeatherData(); _currentConditionsDisplay = new CurrentConditionsDisplay(_weatherData); _forcastDisplay = new ForcastDisplay(_weatherData); _statisticsDisplay = new StatisticsDisplay(_weatherData); _heatIndexDisplay = new HeatIndexDisplay(_weatherData); }
static void DoObserver() { WeatherData weatherData = new WeatherData(); CurrentconditionDisplay currentDisplay = new CurrentconditionDisplay(weatherData); StatisticsDisplay stasticsDisplay = new StatisticsDisplay(weatherData); ForcastDisplay forecastDisplay = new ForcastDisplay(weatherData); weatherData.setMeasurements(80, 65, 30.4f); weatherData.setMeasurements(75, 33, 58.9f); weatherData.setMeasurements(31, 45, 34.7f); }
static void Main(string[] args) { WeatherData weatherData = new WeatherData(); CurrentConditionsDisplay currentConditionsDisplay = new CurrentConditionsDisplay(weatherData); HeatIndexDisplay heatIndexDisplay = new HeatIndexDisplay(weatherData); StatisticsDisplay statisticsDisplay = new StatisticsDisplay(weatherData); ForcastDisplay forcastDisplay = new ForcastDisplay(weatherData); weatherData.SetMeasurements(80, 65, 30.4f); weatherData.SetMeasurements(82, 70, 29.2f); weatherData.SetMeasurements(78, 90, 29.2f); Console.ReadLine(); }
public static void Main() { WeatherData weatherData = new WeatherData(); CurrentConditionsDisplay currentConditionsDisplay = new CurrentConditionsDisplay(weatherData); StatisticsDisplay statisticsDisplay = new StatisticsDisplay(weatherData); ForcastDisplay forcastDisplay = new ForcastDisplay(weatherData); HeatIndexDisplay heatIndexDisplay = new HeatIndexDisplay(weatherData); Console.WriteLine("The Weather Station App..."); weatherData.SetMeasurements(80, 65, 30.4f); weatherData.SetMeasurements(82, 70, 29.2f); weatherData.SetMeasurements(78, 90, 29.2f); Console.ReadLine(); }