public static void FormatOutputDebug <T>(IDomainResponse response) { //InsertBatchPatientsDataResponse //Helpers.SerializeObject<List<PatientData>>(patients as List<PatientData>, System.Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData) + "\\PatientsExample.txt"); //var lPsd = Helpers.DeserializeObject<List<PatientSystemData>>(System.Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData) + "\\PatientsSystemExample.txt"); StringBuilder sb = new StringBuilder(); ((InsertBatchPatientsDataResponse)response).Responses.ForEach(r => { sb.Append("Id: " + r.Body.Id + " ,"); sb.Append("ExternalRecordId: " + r.Body.ExternalRecordId + " ,"); sb.Append("EngageId: " + r.Body.EngagePatientSystemValue + " |"); }); LoggerDomainEvent.Raise(new LogStatus { Message = "patient save result: " + sb.ToString(), Type = LogType.Debug }); }
protected void RaiseException(IDomainResponse response, Exception ex) { FormatUtil.FormatExceptionResponse(response, base.Response, ex); Helpers.LogException(int.Parse(_aseProcessId), ex); }