public class MainPageViewModel:BaseViewModel
    {
        #region Fields

        private ObservableCollection<Person> _persons;
        private Command<int> _selectPersonCommand; 

        #endregion

        #region Constructor

        public MainPageViewModel()
        {
	    this.Persons = new ObservableCollection<Person>();
            this.Persons.Add(new Person { PersonId = 1, Name = "Smith", Age = 22 });
            this.Persons.Add(new Person { PersonId = 2, Name = "Delpin", Age = 23 });
            this.Persons.Add(new Person { PersonId = 1, Name = "Raj", Age = 20 });
            this.Persons.Add(new Person { PersonId = 1, Name = "John", Age = 25 });
        }


        #endregion

        #region Properties

        public ObservableCollection<Person> Persons
        {
            get { return _persons; }
            set { Set(() => Persons, ref _persons, value); }
        }

        public Command<int> SelectPersonCommand
        {
            get 
            {
                return _selectPersonCommand ?? (_selectPersonCommand = new Command<int>((id) =>
                {
                    Application.Current.MainPage.DisplayAlert("Selected Peron", "Person id : " + id.ToString(), "Ok");
                }));
            }
        }

        #endregion

        
    }