
Package org.hl7.fhir.r4.utils
Class NarrativeGenerator
java.lang.Object
org.hl7.fhir.r4.utils.NarrativeGenerator
- All Implemented Interfaces:
INarrativeGenerator
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassstatic interfacestatic interfacestatic interfaceclassstatic classstatic classclassclassclass -
Constructor Summary
ConstructorsConstructorDescriptionNarrativeGenerator(String prefix, String basePath, IWorkerContext context) NarrativeGenerator(String prefix, String basePath, IWorkerContext context, NarrativeGenerator.IReferenceResolver resolver) -
Method Summary
Modifier and TypeMethodDescriptionstatic StringdescribeSystem(String system) static StringdisplayContactPoint(ContactPoint contact) static StringdisplayHumanName(HumanName name) static Stringgen(CodeableConcept code) generate(Element er, boolean showCodeDetails, NarrativeGenerator.ITypeParser parser) booleanbooleangenerate(DomainResource r, Set<String> outputTracker) generate(NarrativeGenerator.ResourceContext rcontext, Element er, boolean showCodeDetails, NarrativeGenerator.ITypeParser parser) booleangenerate(NarrativeGenerator.ResourceContext rcontext, CapabilityStatement conf) booleangenerate(NarrativeGenerator.ResourceContext rcontext, CodeSystem cs, boolean header, String lang) This generate is optimised for the FHIR build process itself in as much as it generates hyperlinks in the narrative that are only going to be correct for the purposes of the build.booleangenerate(NarrativeGenerator.ResourceContext rcontext, CompartmentDefinition cpd) booleangenerate(NarrativeGenerator.ResourceContext rcontext, ConceptMap cm) booleangenerate(NarrativeGenerator.ResourceContext rcontext, DomainResource r, Set<String> outputTracker) booleangenerate(NarrativeGenerator.ResourceContext rcontext, ImplementationGuide ig) booleangenerate(NarrativeGenerator.ResourceContext rcontext, OperationDefinition opd) booleangenerate(NarrativeGenerator.ResourceContext rcontext, OperationOutcome op) This generate is optimised for the build tool in that it tracks the source extension.booleangenerate(NarrativeGenerator.ResourceContext rcontext, StructureDefinition sd, Set<String> outputTracker) booleangenerate(NarrativeGenerator.ResourceContext rcontext, ValueSet vs, boolean header) This generate is optimised for the FHIR build process itself in as much as it generates hyperlinks in the narrative that are only going to be correct for the purposes of the build.voidgenerate(NarrativeGenerator.ResourceContext rcontext, ValueSet vs, ValueSet src, boolean header) generate(NarrativeGenerator.ResourceContext rcontext, Element doc) org.hl7.fhir.utilities.xhtml.XhtmlNodegenerateDiagnosticReport(org.hl7.fhir.r4.utils.NarrativeGenerator.ResourceWrapper dr) org.hl7.fhir.utilities.xhtml.XhtmlNodeintgetNarrative(Element er) getPkp()org.hl7.fhir.utilities.TerminologyServiceOptionsbooleanbooleanisPretty()org.hl7.fhir.utilities.xhtml.XhtmlNoderenderBundle(Element element) org.hl7.fhir.utilities.xhtml.XhtmlNodevoidrenderCSDetailsLink(org.hl7.fhir.utilities.xhtml.XhtmlNode tr, String url) voidsetCanonicalUrlsAsLinks(boolean canonicalUrlsAsLinks) voidsetCorePath(String corePath) voidsetDefinitionsTarget(String definitionsTarget) voidsetDestDir(String destDir) setHeaderLevelContext(int headerLevelContext) setLiquidServices(NarrativeGenerator.ILiquidTemplateProvider templateProvider, IHostApplicationServices services) setPretty(boolean pretty) setSnomedEdition(String snomedEdition) voidsetTerminologyServiceOptions(org.hl7.fhir.utilities.TerminologyServiceOptions terminologyServiceOptions) setTooCostlyNoteEmpty(String tooCostlyNoteEmpty) setTooCostlyNoteNotEmpty(String tooCostlyNoteNotEmpty)
-
Constructor Details
-
NarrativeGenerator
-
NarrativeGenerator
public NarrativeGenerator(String prefix, String basePath, IWorkerContext context, NarrativeGenerator.IReferenceResolver resolver)
-
-
Method Details
-
generate
public boolean generate(Bundle b, boolean evenIfAlreadyHasNarrative, Set<String> outputTracker) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
generate
public boolean generate(DomainResource r, Set<String> outputTracker) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, DomainResource r, Set<String> outputTracker) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
setLiquidServices
public NarrativeGenerator setLiquidServices(NarrativeGenerator.ILiquidTemplateProvider templateProvider, IHostApplicationServices services) -
parseType
public Base parseType(String xml, String type) throws IOException, org.hl7.fhir.exceptions.FHIRException - Throws:
IOExceptionorg.hl7.fhir.exceptions.FHIRException
-
getRenderingMaps
-
getHeaderLevelContext
-
setHeaderLevelContext
-
getTooCostlyNoteEmpty
-
setTooCostlyNoteEmpty
-
getTooCostlyNoteNotEmpty
-
setTooCostlyNoteNotEmpty
-
generate
- Throws:
IOExceptionorg.hl7.fhir.exceptions.FHIRException
-
generate
public String generate(NarrativeGenerator.ResourceContext rcontext, Element doc) throws IOException, org.hl7.fhir.exceptions.FHIRException - Throws:
IOExceptionorg.hl7.fhir.exceptions.FHIRException
-
generate
public String generate(Element er, boolean showCodeDetails, NarrativeGenerator.ITypeParser parser) throws IOException, org.hl7.fhir.exceptions.FHIRException - Throws:
IOExceptionorg.hl7.fhir.exceptions.FHIRException
-
generate
public String generate(NarrativeGenerator.ResourceContext rcontext, Element er, boolean showCodeDetails, NarrativeGenerator.ITypeParser parser) throws IOException, org.hl7.fhir.exceptions.FHIRException - Throws:
IOExceptionorg.hl7.fhir.exceptions.FHIRException
-
displayPeriod
-
describeSystem
-
displayCodeableConcept
-
displayRange
-
displayHumanName
-
displayContactPoint
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, ConceptMap cm) throws org.hl7.fhir.exceptions.FHIRFormatError, org.hl7.fhir.exceptions.DefinitionException, IOException - Throws:
org.hl7.fhir.exceptions.FHIRFormatErrororg.hl7.fhir.exceptions.DefinitionExceptionIOException
-
renderCSDetailsLink
-
getNarrative
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, CodeSystem cs, boolean header, String lang) throws org.hl7.fhir.exceptions.FHIRFormatError, org.hl7.fhir.exceptions.DefinitionException, IOException This generate is optimised for the FHIR build process itself in as much as it generates hyperlinks in the narrative that are only going to be correct for the purposes of the build. This is to be reviewed in the future.- Parameters:
vs-codeSystems-- Throws:
IOExceptionorg.hl7.fhir.exceptions.DefinitionExceptionorg.hl7.fhir.exceptions.FHIRFormatErrorException
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, ValueSet vs, boolean header) throws org.hl7.fhir.exceptions.FHIRException, IOException This generate is optimised for the FHIR build process itself in as much as it generates hyperlinks in the narrative that are only going to be correct for the purposes of the build. This is to be reviewed in the future.- Parameters:
vs-codeSystems-- Throws:
org.hl7.fhir.exceptions.FHIRExceptionIOExceptionException
-
generate
public void generate(NarrativeGenerator.ResourceContext rcontext, ValueSet vs, ValueSet src, boolean header) throws org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
org.hl7.fhir.exceptions.FHIRExceptionIOException
-
sctLink
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, OperationOutcome op) throws org.hl7.fhir.exceptions.DefinitionException This generate is optimised for the build tool in that it tracks the source extension. But it can be used for any other use.- Parameters:
vs-codeSystems-- Throws:
org.hl7.fhir.exceptions.DefinitionExceptionException
-
genType
- Throws:
org.hl7.fhir.exceptions.DefinitionException
-
gen
-
gen
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, StructureDefinition sd, Set<String> outputTracker) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, ImplementationGuide ig) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, OperationDefinition opd) throws EOperationOutcome, org.hl7.fhir.exceptions.FHIRException, IOException - Throws:
EOperationOutcomeorg.hl7.fhir.exceptions.FHIRExceptionIOException
-
generate
-
generate
public boolean generate(NarrativeGenerator.ResourceContext rcontext, CapabilityStatement conf) throws org.hl7.fhir.exceptions.FHIRFormatError, org.hl7.fhir.exceptions.DefinitionException, IOException - Throws:
org.hl7.fhir.exceptions.FHIRFormatErrororg.hl7.fhir.exceptions.DefinitionExceptionIOException
-
generateDocumentNarrative
-
generateDiagnosticReport
public org.hl7.fhir.utilities.xhtml.XhtmlNode generateDiagnosticReport(org.hl7.fhir.r4.utils.NarrativeGenerator.ResourceWrapper dr) -
renderBundle
public org.hl7.fhir.utilities.xhtml.XhtmlNode renderBundle(Bundle b) throws org.hl7.fhir.exceptions.FHIRException - Throws:
org.hl7.fhir.exceptions.FHIRException
-
renderBundle
public org.hl7.fhir.utilities.xhtml.XhtmlNode renderBundle(Element element) throws org.hl7.fhir.exceptions.FHIRException - Throws:
org.hl7.fhir.exceptions.FHIRException
-
getDefinitionsTarget
-
setDefinitionsTarget
-
getCorePath
-
setCorePath
-
getDestDir
-
setDestDir
-
getPkp
-
setPkp
-
isPretty
-
setPretty
-
isCanonicalUrlsAsLinks
-
setCanonicalUrlsAsLinks
- Specified by:
setCanonicalUrlsAsLinksin interfaceINarrativeGenerator
-
getSnomedEdition
-
setSnomedEdition
-
getTerminologyServiceOptions
-
setTerminologyServiceOptions
public void setTerminologyServiceOptions(org.hl7.fhir.utilities.TerminologyServiceOptions terminologyServiceOptions)
-