private static WebPageAddressView create(WebPageAddress o) { var v = new WebPageAddressView { Url = o?.Data?.Address }; setCommonValues(v, o?.Data?.ID, o?.Data?.ValidFrom, o?.Data?.ValidTo); return(v); }
public static WebPageAddress Create(WebPageAddressView v) { var d = new WebPageAddressData { ID = v.ID, Address = v.Url, ValidTo = v.ValidTo ?? DateTime.MaxValue, ValidFrom = v.ValidFrom ?? DateTime.MinValue }; return(new WebPageAddress(d)); }