using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.ServiceModel.Web;
using System.Text;

namespace WcfServicePersonen
{
    public class PersonService : IPersonService
    {
        private List<Person> personen;
        public PersonService()
        {
            personen = new List<Person>();
            
            Person p1 = new Person();
            p1.Alter = 32;
            p1.Name = "Mustermann";
            p1.Vorname = "Max";
            personen.Add(p1);
            
            p1 = new Person();
            p1.Alter = 33;
            p1.Name = "Mustermann";
            p1.Vorname = "Maxine";
            personen.Add(p1);
            
            p1 = new Person();
            p1.Alter = 31;
            p1.Name = "Mustermann";
            p1.Vorname = "Moritz";
            personen.Add(p1);
        }

        public List<Person> GetPersonen()
        {
            return personen;
        }
    }
}
