public Guid AddCustomer(string name, string email, Address address) { var command = new AddCustomerCommand(name, email, address); var result = _processor.ProcessCommand(command); if (result.EventsWereEmitted) { return command.CreatedGuid; } throw new CreationFailedException(command.CreatedGuid, typeof (ICustomer)); }
public void UpdateInfo(string name, string email, Address address) { Name = name; Email = email; Address = address; }