using System;
using System.ComponentModel;
using TheGameExtreme.model.card;

namespace TheGameExtreme.viewmodel
{
    public class CardVM : INotifyPropertyChanged
    {

        public event PropertyChangedEventHandler PropertyChanged;
        public Card View { get; set; }
        private int value;
        public int Value {
            get { return value; }
            set
            {
                this.value = value;
                OnPropertyChanged("Value");
            }
        }
        protected virtual void OnPropertyChanged(string info)
        {
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(info));
        }

        public CardVM(Card view)
        {
            View = view;

            Value = view.Value;
        }
    }
}
