using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WeatherClient.Models;

namespace WeatherClient.ViewModels
{
    public class WeatherViewModel : INotifyPropertyChanged
    {
        public event PropertyChangedEventHandler PropertyChanged;

        private WeatherData _weatherData;
        public WeatherData WeatherData
        {
            get { return _weatherData; }
            set
            {
                _weatherData = value;
                OnPropertyChanged(nameof(WeatherData));
            }
        }


        private void OnPropertyChanged(string propertyName = null)
        {
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
        }
    }
}
