/// <summary> /// Creates a new patient record /// </summary> /// <param name="id"></param> /// <param name="patientName"></param> /// <param name="patientStatus"></param> /// <param name="address"></param> /// <returns></returns> public static Patient CreateNew(Guid id, PatientName patientName, PatientStatus patientStatus, Address address) { return(new Patient(id, patientName, patientStatus, address)); }
private void Apply(PatientNameChangedEvent evt) { _name = new PatientName(evt.Name); }
private Patient(Guid id, PatientName patientName, PatientStatus patientStatus, Address address) { RaiseEvent(new PatientCreatedEvent(id, patientName.Name, patientStatus.Status, address.Street, address.City, address.State, address.Zip)); }