Search in sources :

Example 91 with Endpoint

use of org.hl7.fhir.r4.model.Endpoint in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeOrganization.

protected void composeOrganization(Complex parent, String parentType, String name, Organization element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeDomainResource(t, "Organization", name, element, index);
    for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "Organization", "identifier", element.getIdentifier().get(i), i);
    if (element.hasActiveElement())
        composeBoolean(t, "Organization", "active", element.getActiveElement(), -1);
    for (int i = 0; i < element.getType().size(); i++) composeCodeableConcept(t, "Organization", "type", element.getType().get(i), i);
    if (element.hasNameElement())
        composeString(t, "Organization", "name", element.getNameElement(), -1);
    for (int i = 0; i < element.getAlias().size(); i++) composeString(t, "Organization", "alias", element.getAlias().get(i), i);
    for (int i = 0; i < element.getTelecom().size(); i++) composeContactPoint(t, "Organization", "telecom", element.getTelecom().get(i), i);
    for (int i = 0; i < element.getAddress().size(); i++) composeAddress(t, "Organization", "address", element.getAddress().get(i), i);
    if (element.hasPartOf())
        composeReference(t, "Organization", "partOf", element.getPartOf(), -1);
    for (int i = 0; i < element.getContact().size(); i++) composeOrganizationOrganizationContactComponent(t, "Organization", "contact", element.getContact().get(i), i);
    for (int i = 0; i < element.getEndpoint().size(); i++) composeReference(t, "Organization", "endpoint", element.getEndpoint().get(i), i);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Example 92 with Endpoint

use of org.hl7.fhir.r4.model.Endpoint in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeImagingStudyImagingStudySeriesComponent.

protected void composeImagingStudyImagingStudySeriesComponent(Complex parent, String parentType, String name, ImagingStudy.ImagingStudySeriesComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "series", name, element, index);
    if (element.hasUidElement())
        composeId(t, "ImagingStudy", "uid", element.getUidElement(), -1);
    if (element.hasNumberElement())
        composeUnsignedInt(t, "ImagingStudy", "number", element.getNumberElement(), -1);
    if (element.hasModality())
        composeCoding(t, "ImagingStudy", "modality", element.getModality(), -1);
    if (element.hasDescriptionElement())
        composeString(t, "ImagingStudy", "description", element.getDescriptionElement(), -1);
    if (element.hasNumberOfInstancesElement())
        composeUnsignedInt(t, "ImagingStudy", "numberOfInstances", element.getNumberOfInstancesElement(), -1);
    for (int i = 0; i < element.getEndpoint().size(); i++) composeReference(t, "ImagingStudy", "endpoint", element.getEndpoint().get(i), i);
    if (element.hasBodySite())
        composeCoding(t, "ImagingStudy", "bodySite", element.getBodySite(), -1);
    if (element.hasLaterality())
        composeCoding(t, "ImagingStudy", "laterality", element.getLaterality(), -1);
    for (int i = 0; i < element.getSpecimen().size(); i++) composeReference(t, "ImagingStudy", "specimen", element.getSpecimen().get(i), i);
    if (element.hasStartedElement())
        composeDateTime(t, "ImagingStudy", "started", element.getStartedElement(), -1);
    for (int i = 0; i < element.getPerformer().size(); i++) composeImagingStudyImagingStudySeriesPerformerComponent(t, "ImagingStudy", "performer", element.getPerformer().get(i), i);
    for (int i = 0; i < element.getInstance().size(); i++) composeImagingStudyImagingStudySeriesInstanceComponent(t, "ImagingStudy", "instance", element.getInstance().get(i), i);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Example 93 with Endpoint

use of org.hl7.fhir.r4.model.Endpoint in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeMessageHeaderMessageDestinationComponent.

protected void composeMessageHeaderMessageDestinationComponent(Complex parent, String parentType, String name, MessageHeader.MessageDestinationComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "destination", name, element, index);
    if (element.hasNameElement())
        composeString(t, "MessageHeader", "name", element.getNameElement(), -1);
    if (element.hasTarget())
        composeReference(t, "MessageHeader", "target", element.getTarget(), -1);
    if (element.hasEndpointElement())
        composeUrl(t, "MessageHeader", "endpoint", element.getEndpointElement(), -1);
    if (element.hasReceiver())
        composeReference(t, "MessageHeader", "receiver", element.getReceiver(), -1);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Example 94 with Endpoint

use of org.hl7.fhir.r4.model.Endpoint in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeEndpoint.

protected void composeEndpoint(Complex parent, String parentType, String name, Endpoint element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeDomainResource(t, "Endpoint", name, element, index);
    for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "Endpoint", "identifier", element.getIdentifier().get(i), i);
    if (element.hasStatusElement())
        composeEnum(t, "Endpoint", "status", element.getStatusElement(), -1);
    if (element.hasConnectionType())
        composeCoding(t, "Endpoint", "connectionType", element.getConnectionType(), -1);
    if (element.hasNameElement())
        composeString(t, "Endpoint", "name", element.getNameElement(), -1);
    if (element.hasManagingOrganization())
        composeReference(t, "Endpoint", "managingOrganization", element.getManagingOrganization(), -1);
    for (int i = 0; i < element.getContact().size(); i++) composeContactPoint(t, "Endpoint", "contact", element.getContact().get(i), i);
    if (element.hasPeriod())
        composePeriod(t, "Endpoint", "period", element.getPeriod(), -1);
    for (int i = 0; i < element.getPayloadType().size(); i++) composeCodeableConcept(t, "Endpoint", "payloadType", element.getPayloadType().get(i), i);
    for (int i = 0; i < element.getPayloadMimeType().size(); i++) composeCode(t, "Endpoint", "payloadMimeType", element.getPayloadMimeType().get(i), i);
    if (element.hasAddressElement())
        composeUrl(t, "Endpoint", "address", element.getAddressElement(), -1);
    for (int i = 0; i < element.getHeader().size(); i++) composeString(t, "Endpoint", "header", element.getHeader().get(i), i);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Example 95 with Endpoint

use of org.hl7.fhir.r4.model.Endpoint in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composePractitionerRole.

protected void composePractitionerRole(Complex parent, String parentType, String name, PractitionerRole element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeDomainResource(t, "PractitionerRole", name, element, index);
    for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "PractitionerRole", "identifier", element.getIdentifier().get(i), i);
    if (element.hasActiveElement())
        composeBoolean(t, "PractitionerRole", "active", element.getActiveElement(), -1);
    if (element.hasPeriod())
        composePeriod(t, "PractitionerRole", "period", element.getPeriod(), -1);
    if (element.hasPractitioner())
        composeReference(t, "PractitionerRole", "practitioner", element.getPractitioner(), -1);
    if (element.hasOrganization())
        composeReference(t, "PractitionerRole", "organization", element.getOrganization(), -1);
    for (int i = 0; i < element.getCode().size(); i++) composeCodeableConcept(t, "PractitionerRole", "code", element.getCode().get(i), i);
    for (int i = 0; i < element.getSpecialty().size(); i++) composeCodeableConcept(t, "PractitionerRole", "specialty", element.getSpecialty().get(i), i);
    for (int i = 0; i < element.getLocation().size(); i++) composeReference(t, "PractitionerRole", "location", element.getLocation().get(i), i);
    for (int i = 0; i < element.getHealthcareService().size(); i++) composeReference(t, "PractitionerRole", "healthcareService", element.getHealthcareService().get(i), i);
    for (int i = 0; i < element.getTelecom().size(); i++) composeContactPoint(t, "PractitionerRole", "telecom", element.getTelecom().get(i), i);
    for (int i = 0; i < element.getAvailableTime().size(); i++) composePractitionerRolePractitionerRoleAvailableTimeComponent(t, "PractitionerRole", "availableTime", element.getAvailableTime().get(i), i);
    for (int i = 0; i < element.getNotAvailable().size(); i++) composePractitionerRolePractitionerRoleNotAvailableComponent(t, "PractitionerRole", "notAvailable", element.getNotAvailable().get(i), i);
    if (element.hasAvailabilityExceptionsElement())
        composeString(t, "PractitionerRole", "availabilityExceptions", element.getAvailabilityExceptionsElement(), -1);
    for (int i = 0; i < element.getEndpoint().size(); i++) composeReference(t, "PractitionerRole", "endpoint", element.getEndpoint().get(i), i);
}
Also used : Complex(org.hl7.fhir.r4.utils.formats.Turtle.Complex)

Aggregations

Test (org.junit.jupiter.api.Test)36 Endpoint (org.hl7.fhir.dstu3.model.Endpoint)21 RequestDetails (ca.uhn.fhir.rest.api.server.RequestDetails)18 StringAndListParam (ca.uhn.fhir.rest.param.StringAndListParam)16 RestIntegrationTest (org.opencds.cqf.ruler.test.RestIntegrationTest)16 SpringBootTest (org.springframework.boot.test.context.SpringBootTest)16 IGenericClient (ca.uhn.fhir.rest.client.api.IGenericClient)15 Endpoint (org.hl7.fhir.r4.model.Endpoint)15 Complex (org.hl7.fhir.dstu3.utils.formats.Turtle.Complex)14 Complex (org.hl7.fhir.r4.utils.formats.Turtle.Complex)14 Bundle (org.hl7.fhir.r4.model.Bundle)12 Organization (org.hl7.fhir.dstu3.model.Organization)11 Resource (org.hl7.fhir.r4.model.Resource)10 Resource (org.hl7.fhir.dstu3.model.Resource)9 Operation (ca.uhn.fhir.rest.annotation.Operation)7 List (java.util.List)7 Bundle (org.hl7.fhir.dstu3.model.Bundle)7 Description (ca.uhn.fhir.model.api.annotation.Description)6 MethodOutcome (ca.uhn.fhir.rest.api.MethodOutcome)6 ArrayList (java.util.ArrayList)6