public static CountryContract ConvertToCountryContract(Country country) { if (country == null) { return(null); } CountryContract contractCountry = new CountryContract() { CountryID = country.CountryID, Name = country.Name, }; return(contractCountry); }
public static Country ConvertToCountryEntity(CountryContract country) { if (country == null) { return(null); } Country entityCountry = new Country() { CountryID = country.CountryID, Name = country.Name, }; return(entityCountry); }