using System;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.ServiceModel.Activation;
using System.ServiceModel.Web;

namespace MicrosoftAJAXDemo
{
    [ServiceContract(Namespace = "http://ajaxbooksamples.com")]
    [AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Allowed)]
    public class PersonService
    {
        [OperationContract]
        public Person GetPerson(string name)
        {
            return new Person(name,"Last Name");
        }
        [OperationContract]
        public Person GetPersonAdvanced(PersonQuery query)
        {
            return new Person(query.FirstName, query.LastName);
        }
    }
}
