Search in sources :

Example 1 with SectionComponent

use of org.hl7.fhir.dstu3.model.Composition.SectionComponent in project gpconnect-demonstrator by nhsconnect.

the class FhirSectionBuilder method buildFhirSection.

public static SectionComponent buildFhirSection(Page page) {
    Coding coding = new Coding().setSystem(SystemURL.VS_GPC_RECORD_SECTION).setCode(page.getCode()).setDisplay(page.getName());
    CodeableConcept codableConcept = new CodeableConcept().addCoding(coding);
    codableConcept.setText(page.getName());
    Narrative narrative = new Narrative();
    narrative.setStatus(NarrativeStatus.GENERATED);
    narrative.setDivAsString(createHtmlContent(page));
    SectionComponent sectionComponent = new SectionComponent();
    sectionComponent.setCode(codableConcept);
    sectionComponent.setTitle(page.getName()).setCode(codableConcept).setText(narrative);
    return sectionComponent;
}
Also used : Coding(org.hl7.fhir.dstu3.model.Coding) Narrative(org.hl7.fhir.dstu3.model.Narrative) SectionComponent(org.hl7.fhir.dstu3.model.Composition.SectionComponent) CodeableConcept(org.hl7.fhir.dstu3.model.CodeableConcept)

Aggregations

CodeableConcept (org.hl7.fhir.dstu3.model.CodeableConcept)1 Coding (org.hl7.fhir.dstu3.model.Coding)1 SectionComponent (org.hl7.fhir.dstu3.model.Composition.SectionComponent)1 Narrative (org.hl7.fhir.dstu3.model.Narrative)1