.forEach(entry -> { if (ResourceType.DocumentReference == entry.getResource().getResourceType()) { if (!expectedReferenceFullUrls.remove(entry.getFullUrl())) { throw FhirUtils.unprocessableEntity( OperationOutcome.IssueSeverity.ERROR, null, null, "DocumentReference with URL %s is not referenced by any DocumentManifest", entry.getFullUrl() ); if (!expectedBinaryFullUrls.remove(entry.getFullUrl())) { throw FhirUtils.unprocessableEntity( OperationOutcome.IssueSeverity.ERROR, null, null, "Binary with URL %s is not referenced by any DocumentReference", entry.getFullUrl() );
public org.hl7.fhir.instance.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; if (advisor.ignoreEntry(src)) return null; org.hl7.fhir.instance.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.instance.model.Bundle.BundleEntryComponent(); copyElement(src, tgt); for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink()) tgt.addLink(convertBundleLinkComponent(t)); tgt.setFullUrl(src.getFullUrl()); org.hl7.fhir.instance.model.Resource res = advisor.convert(src.getResource()); if (res == null) res = convertResource(src.getResource()); tgt.setResource(res); if (src.hasSearch()) tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch())); if (src.hasRequest()) tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest())); if (src.hasResponse()) tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse())); return tgt; }
public static org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent(); copyElement(src, tgt); for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink()) tgt.addLink(convertBundleLinkComponent(t)); if (src.hasFullUrl()) tgt.setFullUrl(src.getFullUrl()); tgt.setResource(convertResource(src.getResource())); tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch())); tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest())); tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse())); return tgt; }
@Override public String getFullUrl(Bundle.BundleEntryComponent theEntry) { return theEntry.getFullUrl(); }
public org.hl7.fhir.instance.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; if (advisor.ignoreEntry(src)) return null; org.hl7.fhir.instance.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.instance.model.Bundle.BundleEntryComponent(); copyElement(src, tgt); for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink()) tgt.addLink(convertBundleLinkComponent(t)); tgt.setFullUrl(src.getFullUrl()); org.hl7.fhir.instance.model.Resource res = advisor.convert(src.getResource()); if (res == null) res = convertResource(src.getResource()); tgt.setResource(res); if (src.hasSearch()) tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch())); if (src.hasRequest()) tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest())); if (src.hasResponse()) tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse())); return tgt; }
public static org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent convertBundleEntryComponent(org.hl7.fhir.dstu3.model.Bundle.BundleEntryComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent tgt = new org.hl7.fhir.dstu2016may.model.Bundle.BundleEntryComponent(); copyElement(src, tgt); for (org.hl7.fhir.dstu3.model.Bundle.BundleLinkComponent t : src.getLink()) tgt.addLink(convertBundleLinkComponent(t)); if (src.hasFullUrl()) tgt.setFullUrl(src.getFullUrl()); tgt.setResource(convertResource(src.getResource())); tgt.setSearch(convertBundleEntrySearchComponent(src.getSearch())); tgt.setRequest(convertBundleEntryRequestComponent(src.getRequest())); tgt.setResponse(convertBundleEntryResponseComponent(src.getResponse())); return tgt; }
@Override public String getFullUrl(Bundle.BundleEntryComponent theEntry) { return theEntry.getFullUrl(); }