Search in sources :

Example 11 with Complex

use of org.hl7.fhir.r4.utils.formats.Turtle.Complex in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeDocumentManifest.

protected void composeDocumentManifest(Complex parent, String parentType, String name, DocumentManifest element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeDomainResource(t, "DocumentManifest", name, element, index);
    if (element.hasMasterIdentifier())
        composeIdentifier(t, "DocumentManifest", "masterIdentifier", element.getMasterIdentifier(), -1);
    for (int i = 0; i < element.getIdentifier().size(); i++) composeIdentifier(t, "DocumentManifest", "identifier", element.getIdentifier().get(i), i);
    if (element.hasSubject())
        composeReference(t, "DocumentManifest", "subject", element.getSubject(), -1);
    for (int i = 0; i < element.getRecipient().size(); i++) composeReference(t, "DocumentManifest", "recipient", element.getRecipient().get(i), i);
    if (element.hasType())
        composeCodeableConcept(t, "DocumentManifest", "type", element.getType(), -1);
    for (int i = 0; i < element.getAuthor().size(); i++) composeReference(t, "DocumentManifest", "author", element.getAuthor().get(i), i);
    if (element.hasCreatedElement())
        composeDateTime(t, "DocumentManifest", "created", element.getCreatedElement(), -1);
    if (element.hasSourceElement())
        composeUri(t, "DocumentManifest", "source", element.getSourceElement(), -1);
    if (element.hasStatusElement())
        composeEnum(t, "DocumentManifest", "status", element.getStatusElement(), -1);
    if (element.hasDescriptionElement())
        composeString(t, "DocumentManifest", "description", element.getDescriptionElement(), -1);
    for (int i = 0; i < element.getContent().size(); i++) composeDocumentManifestDocumentManifestContentComponent(t, "DocumentManifest", "content", element.getContent().get(i), i);
    for (int i = 0; i < element.getRelated().size(); i++) composeDocumentManifestDocumentManifestRelatedComponent(t, "DocumentManifest", "related", element.getRelated().get(i), i);
}
Also used : Complex(org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)

Example 12 with Complex

use of org.hl7.fhir.r4.utils.formats.Turtle.Complex in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeContractValuedItemComponent.

protected void composeContractValuedItemComponent(Complex parent, String parentType, String name, Contract.ValuedItemComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "valuedItem", name, element, index);
    if (element.hasEntity())
        composeType(t, "Contract", "entity", element.getEntity(), -1);
    if (element.hasIdentifier())
        composeIdentifier(t, "Contract", "identifier", element.getIdentifier(), -1);
    if (element.hasEffectiveTimeElement())
        composeDateTime(t, "Contract", "effectiveTime", element.getEffectiveTimeElement(), -1);
    if (element.hasQuantity())
        composeQuantity(t, "Contract", "quantity", element.getQuantity(), -1);
    if (element.hasUnitPrice())
        composeQuantity(t, "Contract", "unitPrice", element.getUnitPrice(), -1);
    if (element.hasFactorElement())
        composeDecimal(t, "Contract", "factor", element.getFactorElement(), -1);
    if (element.hasPointsElement())
        composeDecimal(t, "Contract", "points", element.getPointsElement(), -1);
    if (element.hasNet())
        composeQuantity(t, "Contract", "net", element.getNet(), -1);
}
Also used : Complex(org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)

Example 13 with Complex

use of org.hl7.fhir.r4.utils.formats.Turtle.Complex in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeExplanationOfBenefitDiagnosisComponent.

protected void composeExplanationOfBenefitDiagnosisComponent(Complex parent, String parentType, String name, ExplanationOfBenefit.DiagnosisComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "diagnosis", name, element, index);
    if (element.hasSequenceElement())
        composePositiveInt(t, "ExplanationOfBenefit", "sequence", element.getSequenceElement(), -1);
    if (element.hasDiagnosis())
        composeCoding(t, "ExplanationOfBenefit", "diagnosis", element.getDiagnosis(), -1);
}
Also used : Complex(org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)

Example 14 with Complex

use of org.hl7.fhir.r4.utils.formats.Turtle.Complex in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeImplementationGuideImplementationGuideDependencyComponent.

protected void composeImplementationGuideImplementationGuideDependencyComponent(Complex parent, String parentType, String name, ImplementationGuide.ImplementationGuideDependencyComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "dependency", name, element, index);
    if (element.hasTypeElement())
        composeEnum(t, "ImplementationGuide", "type", element.getTypeElement(), -1);
    if (element.hasUriElement())
        composeUri(t, "ImplementationGuide", "uri", element.getUriElement(), -1);
}
Also used : Complex(org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)

Example 15 with Complex

use of org.hl7.fhir.r4.utils.formats.Turtle.Complex in project org.hl7.fhir.core by hapifhir.

the class RdfParser method composeExplanationOfBenefitDetailComponent.

protected void composeExplanationOfBenefitDetailComponent(Complex parent, String parentType, String name, ExplanationOfBenefit.DetailComponent element, int index) {
    if (element == null)
        return;
    Complex t;
    if (Utilities.noString(parentType))
        t = parent;
    else {
        t = parent.predicate("fhir:" + parentType + '.' + name);
    }
    composeBackboneElement(t, "detail", name, element, index);
    if (element.hasSequenceElement())
        composePositiveInt(t, "ExplanationOfBenefit", "sequence", element.getSequenceElement(), -1);
    if (element.hasType())
        composeCoding(t, "ExplanationOfBenefit", "type", element.getType(), -1);
    if (element.hasService())
        composeCoding(t, "ExplanationOfBenefit", "service", element.getService(), -1);
    for (int i = 0; i < element.getProgramCode().size(); i++) composeCoding(t, "ExplanationOfBenefit", "programCode", element.getProgramCode().get(i), i);
    if (element.hasQuantity())
        composeQuantity(t, "ExplanationOfBenefit", "quantity", element.getQuantity(), -1);
    if (element.hasUnitPrice())
        composeQuantity(t, "ExplanationOfBenefit", "unitPrice", element.getUnitPrice(), -1);
    if (element.hasFactorElement())
        composeDecimal(t, "ExplanationOfBenefit", "factor", element.getFactorElement(), -1);
    if (element.hasPointsElement())
        composeDecimal(t, "ExplanationOfBenefit", "points", element.getPointsElement(), -1);
    if (element.hasNet())
        composeQuantity(t, "ExplanationOfBenefit", "net", element.getNet(), -1);
    for (int i = 0; i < element.getUdi().size(); i++) composeReference(t, "ExplanationOfBenefit", "udi", element.getUdi().get(i), i);
    for (int i = 0; i < element.getAdjudication().size(); i++) composeExplanationOfBenefitDetailAdjudicationComponent(t, "ExplanationOfBenefit", "adjudication", element.getAdjudication().get(i), i);
    for (int i = 0; i < element.getSubDetail().size(); i++) composeExplanationOfBenefitSubDetailComponent(t, "ExplanationOfBenefit", "subDetail", element.getSubDetail().get(i), i);
}
Also used : Complex(org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)

Aggregations

Complex (org.hl7.fhir.r4.utils.formats.Turtle.Complex)679 Complex (org.hl7.fhir.dstu2016may.formats.RdfGenerator.Complex)506 Complex (org.hl7.fhir.dstu3.utils.formats.Turtle.Complex)504 ElementDefinition (org.hl7.fhir.r5.model.ElementDefinition)12 FHIRException (org.hl7.fhir.exceptions.FHIRException)9 Cell (org.hl7.fhir.utilities.xhtml.HierarchicalTableGenerator.Cell)9 ArrayList (java.util.ArrayList)7 Piece (org.hl7.fhir.utilities.xhtml.HierarchicalTableGenerator.Piece)7 Row (org.hl7.fhir.utilities.xhtml.HierarchicalTableGenerator.Row)7 URISyntaxException (java.net.URISyntaxException)6 JsonElement (com.google.gson.JsonElement)5 IOException (java.io.IOException)5 HashSet (java.util.HashSet)5 TypeRefComponent (org.hl7.fhir.r5.model.ElementDefinition.TypeRefComponent)5 URI (java.net.URI)4 FHIRFormatError (org.hl7.fhir.exceptions.FHIRFormatError)3 MalformedURLException (java.net.MalformedURLException)2 ElementDefinition (org.hl7.fhir.dstu2.model.ElementDefinition)2 StructureDefinition (org.hl7.fhir.dstu2.model.StructureDefinition)2 ElementDefinition (org.hl7.fhir.dstu2016may.model.ElementDefinition)2