Search in sources :

Example 46 with Consent

use of org.hl7.fhir.dstu3.model.Consent in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeConsentConsentPolicyComponent.

protected void composeConsentConsentPolicyComponent(Complex parent, String parentType, String name, Consent.ConsentPolicyComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "policy", name, element, index);
    if (element.hasAuthorityElement())
        composeUri(t, "Consent", "authority", element.getAuthorityElement(), -1);
    if (element.hasUriElement())
        composeUri(t, "Consent", "uri", element.getUriElement(), -1);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Aggregations

Consent (org.hl7.fhir.r4.model.Consent)15 Consent (org.hl7.fhir.dstu3.model.Consent)8 Complex (org.hl7.fhir.dstu3.utils.formats.Turtle.Complex)8 Complex (org.hl7.fhir.r4.utils.formats.Turtle.Complex)7 Test (org.junit.jupiter.api.Test)7 MethodOutcome (ca.uhn.fhir.rest.api.MethodOutcome)6 List (java.util.List)5 Bundle (org.hl7.fhir.r4.model.Bundle)5 Reference (org.hl7.fhir.r4.model.Reference)5 ResourceNotFoundException (ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException)4 ConsentEntity (gov.cms.dpc.common.consent.entities.ConsentEntity)4 Optional (java.util.Optional)4 Collectors (java.util.stream.Collectors)4 IIdType (org.hl7.fhir.instance.model.api.IIdType)4 ConsentCreateException (org.hl7.gravity.refimpl.sdohexchange.exception.ConsentCreateException)4 IGenericClient (ca.uhn.fhir.rest.client.api.IGenericClient)3 SmartOnFhirContext (com.healthlx.smartonfhir.core.SmartOnFhirContext)2 DPCIdentifierSystem (gov.cms.dpc.fhir.DPCIdentifierSystem)2 FHIR (gov.cms.dpc.fhir.annotations.FHIR)2 UnitOfWork (io.dropwizard.hibernate.UnitOfWork)2