Пример #1
0
        public void NotifyObservers()
        {
            var update = new TimeInfosDto()
            {
                Tempery  = _tempery,
                Pressure = _pressure,
                Umity    = _umity
            };

            foreach (var observer in _observers)
            {
                observer.Update(update);
            }
        }
 public void Update(TimeInfosDto update)
 {
     _tempery  = update.Tempery;
     _umity    = update.Umity;
     _pressure = update.Pressure;
 }