private void IdentifieBatchEntityToClient(OperationOutcome op, string FullURL, string OperationType, int EntityIndexInType) { EntityIndexInType = EntityIndexInType + 1; string Message = string.Empty; if (String.IsNullOrWhiteSpace(FullURL)) { Message = $"The Issue/s were found in the {EntityIndexInType.Ordinal()} {OperationType} bundel entry"; } else { Message = $"The Issue/s were found in the bundel entry identified by the FullURL: {FullURL}"; } OperationOutcome NewOp = FhirOperationOutcomeSupport.Append(OperationOutcome.IssueSeverity.Information, OperationOutcome.IssueType.Informational, Message, op); }
private OperationOutcome GenerateUnsupportedParameterOperationOutcome() { if (this.SearchParameters == null || this.SearchParameters.UnspportedSearchParameterList == null || this.SearchParameters.UnspportedSearchParameterList.Count == 0) { string ExceptionMessage = "Server Internal Error: Attempt to generate unsupported search parameter OperationOutcome when there were no unsupported search parameters to process."; throw new Pyro.Common.Exceptions.PyroException(HttpStatusCode.Forbidden, FhirOperationOutcomeSupport.Create(OperationOutcome.IssueSeverity.Fatal, OperationOutcome.IssueType.Exception, ExceptionMessage), ExceptionMessage); } var OpOut = new OperationOutcome(); foreach (UnspportedSearchParameter Parameter in SearchParameters.UnspportedSearchParameterList) { string Message = $"Unable to process a search parameter: {Parameter.ReasonMessage}"; FhirOperationOutcomeSupport.Append(OperationOutcome.IssueSeverity.Error, OperationOutcome.IssueType.Processing, Message, OpOut); } return(OpOut); }