public static void Delete(this Business business)
 {
     addressRepository.Delete(business.Address);
     businessRepository.Delete(business);
 }
 public static void Save(this Business business)
 {
     businessRepository.Save(business);
     addressRepository.Save(business.Address);
 }
 public static Business Find(this Business business, Guid?id)
 {
     return(new Business(businessRepository.Find(id)));
 }
Пример #4
0
 //created constructor for test scenarios like: Assert.AreEqual(savedPerson.adress, address);
 public Business(Business newBusiness)
 {
     Name    = newBusiness.Name;
     ID      = newBusiness.ID;
     Address = new Address(newBusiness.Address);
 }