oop_NFS_Andreas/Plattform/Plattform/Models/Airport.cs

34 lines
799 B
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Runtime.Serialization;
using Plattform;
namespace Plattform.Models
{
[DataContract]
public class Airport
{
[DataMember]
public string ShortName { get; set; }
[DataMember]
public string Name { get; set; }
[DataMember]
public virtual City City { get; set; }
public Airport() { }
public Airport(AirlineService.Airport airport)
{
City city = new City
{
Name = airport.City.Name,
ZipCode = airport.City.ZipCode,
};
this.Name = airport.Name;
this.City = city;
this.ShortName = airport.ShortName;
}
}
}