Guide d'implémentation du GT Standards et Interopérabilité pour les EDS
0.1.0 - ci-build
Guide d'implémentation du GT Standards et Interopérabilité pour les EDS - Local Development build (v0.1.0) built by the FHIR (HL7® FHIR® Standard) Build Tools. See the Directory of published versions
Draft as of 2024-11-23 |
<StructureMap xmlns="http://hl7.org/fhir">
<id value="SimpleObservation"/>
<text>
<status value="generated"/>
<div xmlns="http://www.w3.org/1999/xhtml"><p class="res-header-id"><b>Generated Narrative: StructureMap SimpleObservation</b></p><a name="SimpleObservation"> </a><a name="hcSimpleObservation"> </a><a name="SimpleObservation-fr-FR"> </a><pre class="fml">
<b>map</b><span style="color: navy"> "</span>https://interop.esante.gouv.fr/ig/fhir/eds/StructureMap/SimpleObservation<span style="color: navy">" = "</span>SimpleObservation<span style="color: navy">"
</span><span style="color: navy">// </span><span style="color: green">Mapping simple Observation laboratory resources to Measurement OMOP Domain</span>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-EDSObservationLaboratoryGeneric.html" title="Résultat de laboratoire">https://interop.esante.gouv.fr/ig/fhir/eds/StructureDefinition/EDSObservationLaboratoryGeneric</a><span style="color: navy">" </span><b>alias </b>LabObs <b>as </b><b>source</b>
<b>uses</b><span style="color: navy"> "</span><a href="StructureDefinition-OMOPMeasurement.html" title="Measurement OMOP Table">https://interop.esante.gouv.fr/ig/fhir/eds/StructureDefinition/OMOPMeasurement</a><span style="color: navy">" </span><b>alias </b>MeasurementTable <b>as </b><b>target</b>
<b>group </b>SimpleObservation<span style="color: navy">(</span><b>source</b> <span style="color: maroon">src</span><span style="color: navy"> : </span>LabObs, <b>target</b> <span style="color: maroon">tgt</span><span style="color: navy"> : </span>MeasurementTable<span style="color: navy">)</span><span style="color: navy"> {
</span> src.subject<b> as </b><span style="color: maroon">srcSubject</span><span style="color: navy"><b> -> </b></span>tgt.person_id = <span style="color: maroon">srcSubject</span> <i>"setSubject"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">reference impropre dans le monde OMOP mais permet d'illustrer l'information qui doit être utilisée pour retrouver la bonne OMOPPerson</span>
src.code<b> as </b><span style="color: maroon">srcCode</span><span style="color: navy"><b> -> </b></span>tgt.measurement_concept_id = <b>create</b><span style="color: navy">(</span><span style="color: blue">'Reference'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">tgtReference</span><b> then</b><span style="color: navy"> {
</span> srcCode.coding<b> as </b><span style="color: maroon">srcCoding</span><span style="color: navy"><b> -> </b></span> <b>translate</b><span style="color: navy">(</span><span style="color: maroon">srcCoding</span><span style="color: navy">, </span><span style="color: blue">'https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabAnalyses'</span><span style="color: navy">, </span><span style="color: blue">'code'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">measurementCode</span><span style="color: navy">, </span> tgtReference.reference = <b>append</b><span style="color: navy">(</span><span style="color: blue">'Concept/'</span><span style="color: navy">, </span><span style="color: maroon">measurementCode</span><span style="color: navy">)</span> <i>"setMeasurementConcept"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"createMeasurementConcept"</i><span style="color: navy">;</span>
src.effective<span style="color: navy"> : </span>dateTime<b> as </b><span style="color: maroon">srcDateTime</span><b> then</b><span style="color: navy"> {
</span> srcDateTime<span style="color: navy"><b> -> </b></span>tgt.measurement_datetime = <span style="color: maroon">srcDateTime</span> <i>"setDateTime"</i><span style="color: navy">;</span>
srcDateTime<span style="color: navy"><b> -> </b></span>tgt.measurement_date = <span style="color: navy">(</span>%srcDateTime.toString().substring(0, 10)<span style="color: navy">)</span> <i>"setDateNotTime"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"SetDate"</i><span style="color: navy">;</span>
src.value<span style="color: navy"> : </span>Quantity<b> as </b><span style="color: maroon">srcValueQuantity</span><b> then</b><span style="color: navy"> {
</span> srcValueQuantity.value<b> as </b><span style="color: maroon">srcResultValue</span><span style="color: navy"><b> -> </b></span>tgt.value_as_number = <span style="color: maroon">srcResultValue</span> <i>"setResultValue"</i><span style="color: navy">;</span>
srcValueQuantity<span style="color: navy"><b> -> </b></span>tgt.operator_concept_id = <b>create</b><span style="color: navy">(</span><span style="color: blue">'Reference'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">tgtReference</span><b> then</b><span style="color: navy"> {
</span> srcValueQuantity.comparator<b> as </b><span style="color: maroon">srcValueComparator</span><span style="color: navy"><b> -> </b></span> <b>translate</b><span style="color: navy">(</span><span style="color: maroon">srcValueComparator</span><span style="color: navy">, </span><span style="color: blue">'https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabComparator'</span><span style="color: navy">, </span><span style="color: blue">'code'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">comparatorCode</span><span style="color: navy">, </span> tgtReference.reference = <b>append</b><span style="color: navy">(</span><span style="color: blue">'Concept/'</span><span style="color: navy">, </span><span style="color: maroon">comparatorCode</span><span style="color: navy">)</span> <i>"setComparatorConcept"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"createComparatorConcept"</i><span style="color: navy">;</span>
srcValueQuantity<span style="color: navy"><b> -> </b></span>tgt.unit_concept_id = <b>create</b><span style="color: navy">(</span><span style="color: blue">'Reference'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">tgtReference</span><b> then</b><span style="color: navy"> {
</span> srcValueQuantity.code<b> as </b><span style="color: maroon">srcValueCode</span><span style="color: navy"><b> -> </b></span> <b>translate</b><span style="color: navy">(</span><span style="color: maroon">srcValueCode</span><span style="color: navy">, </span><span style="color: blue">'https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabUnit'</span><span style="color: navy">, </span><span style="color: blue">'code'</span><span style="color: navy">)</span><b> as </b><span style="color: maroon">unitCode</span><span style="color: navy">, </span> tgtReference.reference = <b>append</b><span style="color: navy">(</span><span style="color: blue">'Concept/'</span><span style="color: navy">, </span><span style="color: maroon">unitCode</span><span style="color: navy">)</span> <i>"createUnitConcept"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setUnitConcept"</i><span style="color: navy">;</span>
srcValueQuantity.code<b> as </b><span style="color: maroon">srcValueCode</span><span style="color: navy"><b> -> </b></span>tgt.unit_source_value = <span style="color: maroon">srcValueCode</span> <i>"setUnitSourceValue"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"SetValue"</i><span style="color: navy">;</span>
src.referenceRange<b> as </b><span style="color: maroon">srcRange</span><b> then</b><span style="color: navy"> {
</span> srcRange.low<b> as </b><span style="color: maroon">srcRangeLow</span><b> then</b><span style="color: navy"> {
</span> srcRangeLow.value<b> as </b><span style="color: maroon">srcRangeLowValue</span><span style="color: navy"><b> -> </b></span>tgt.range_low = <span style="color: maroon">srcRangeLowValue</span> <i>"setRangeLow1"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setRangeLow0"</i><span style="color: navy">;</span>
srcRange.high<b> as </b><span style="color: maroon">srcRangeHigh</span><b> then</b><span style="color: navy"> {
</span> srcRangeHigh.value<b> as </b><span style="color: maroon">srcRangeHighValue</span><span style="color: navy"><b> -> </b></span>tgt.range_high = <span style="color: maroon">srcRangeHighValue</span> <i>"setRangeHigh1"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setRangeHigh0"</i><span style="color: navy">;</span>
<span style="color: navy">}</span> <i>"setRange"</i><span style="color: navy">;</span>
src.performer<b> as </b><span style="color: maroon">srcPerformer</span><span style="color: navy"><b> -> </b></span>tgt.provider_id = <span style="color: maroon">srcPerformer</span> <i>"setPerformer"</i><span style="color: navy">;</span> <span style="color: navy">// </span><span style="color: green">reference impropre dans le monde OMOP mais permet d'illustrer l'information qui doit être utilisée pour retrouver le bon OMOPProvider</span>
<span style="color: navy">}
</span></pre></div>
</text>
<url
value="https://interop.esante.gouv.fr/ig/fhir/eds/StructureMap/SimpleObservation"/>
<version value="0.1.0"/>
<name value="SimpleObservation"/>
<title
value="Mapping simple Observation laboratory resources to Measurement OMOP Domain"/>
<status value="draft"/>
<date value="2024-11-23T19:10:09+00:00"/>
<publisher value="ANS"/>
<contact>
<name value="ANS"/>
<telecom>
<system value="url"/>
<value value="https://esante.gouv.fr"/>
</telecom>
</contact>
<description
value="Mapping simple Observation laboratory resources to Measurement OMOP Domain"/>
<jurisdiction>
<coding>
<system value="urn:iso:std:iso:3166"/>
<code value="FR"/>
<display value="France"/>
</coding>
</jurisdiction>
<structure>
<url
value="https://interop.esante.gouv.fr/ig/fhir/eds/StructureDefinition/EDSObservationLaboratoryGeneric"/>
<mode value="source"/>
<alias value="LabObs"/>
</structure>
<structure>
<url
value="https://interop.esante.gouv.fr/ig/fhir/eds/StructureDefinition/OMOPMeasurement"/>
<mode value="target"/>
<alias value="MeasurementTable"/>
</structure>
<group>
<name value="SimpleObservation"/>
<typeMode value="none"/>
<input>
<name value="src"/>
<type value="LabObs"/>
<mode value="source"/>
</input>
<input>
<name value="tgt"/>
<type value="MeasurementTable"/>
<mode value="target"/>
</input>
<rule>
<name value="setSubject"/>
<source>
<context value="src"/>
<element value="subject"/>
<variable value="srcSubject"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="person_id"/>
<transform value="copy"/>
<parameter>
<valueId value="srcSubject"/>
</parameter>
</target>
<documentation
value="reference impropre dans le monde OMOP mais permet d'illustrer l'information qui doit être utilisée pour retrouver la bonne OMOPPerson"/>
</rule>
<rule>
<name value="createMeasurementConcept"/>
<source>
<context value="src"/>
<element value="code"/>
<variable value="srcCode"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="measurement_concept_id"/>
<variable value="tgtReference"/>
<transform value="create"/>
<parameter>
<valueString value="Reference"/>
</parameter>
</target>
<rule>
<name value="setMeasurementConcept"/>
<source>
<context value="srcCode"/>
<element value="coding"/>
<variable value="srcCoding"/>
</source>
<target>
<contextType value="variable"/>
<variable value="measurementCode"/>
<transform value="translate"/>
<parameter>
<valueId value="srcCoding"/>
</parameter>
<parameter>
<valueString
value="https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabAnalyses"/>
</parameter>
<parameter>
<valueString value="code"/>
</parameter>
</target>
<target>
<context value="tgtReference"/>
<contextType value="variable"/>
<element value="reference"/>
<transform value="append"/>
<parameter>
<valueString value="Concept/"/>
</parameter>
<parameter>
<valueId value="measurementCode"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="SetDate"/>
<source>
<context value="src"/>
<type value="dateTime"/>
<element value="effective"/>
<variable value="srcDateTime"/>
</source>
<rule>
<name value="setDateTime"/>
<source>
<context value="srcDateTime"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="measurement_datetime"/>
<transform value="copy"/>
<parameter>
<valueId value="srcDateTime"/>
</parameter>
</target>
</rule>
<rule>
<name value="setDateNotTime"/>
<source>
<context value="srcDateTime"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="measurement_date"/>
<transform value="evaluate"/>
<parameter>
<valueString value="%srcDateTime.toString().substring(0, 10)"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="SetValue"/>
<source>
<context value="src"/>
<type value="Quantity"/>
<element value="value"/>
<variable value="srcValueQuantity"/>
</source>
<rule>
<name value="setResultValue"/>
<source>
<context value="srcValueQuantity"/>
<element value="value"/>
<variable value="srcResultValue"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="value_as_number"/>
<transform value="copy"/>
<parameter>
<valueId value="srcResultValue"/>
</parameter>
</target>
</rule>
<rule>
<name value="createComparatorConcept"/>
<source>
<context value="srcValueQuantity"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="operator_concept_id"/>
<variable value="tgtReference"/>
<transform value="create"/>
<parameter>
<valueString value="Reference"/>
</parameter>
</target>
<rule>
<name value="setComparatorConcept"/>
<source>
<context value="srcValueQuantity"/>
<element value="comparator"/>
<variable value="srcValueComparator"/>
</source>
<target>
<contextType value="variable"/>
<variable value="comparatorCode"/>
<transform value="translate"/>
<parameter>
<valueId value="srcValueComparator"/>
</parameter>
<parameter>
<valueString
value="https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabComparator"/>
</parameter>
<parameter>
<valueString value="code"/>
</parameter>
</target>
<target>
<context value="tgtReference"/>
<contextType value="variable"/>
<element value="reference"/>
<transform value="append"/>
<parameter>
<valueString value="Concept/"/>
</parameter>
<parameter>
<valueId value="comparatorCode"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setUnitConcept"/>
<source>
<context value="srcValueQuantity"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="unit_concept_id"/>
<variable value="tgtReference"/>
<transform value="create"/>
<parameter>
<valueString value="Reference"/>
</parameter>
</target>
<rule>
<name value="createUnitConcept"/>
<source>
<context value="srcValueQuantity"/>
<element value="code"/>
<variable value="srcValueCode"/>
</source>
<target>
<contextType value="variable"/>
<variable value="unitCode"/>
<transform value="translate"/>
<parameter>
<valueId value="srcValueCode"/>
</parameter>
<parameter>
<valueString
value="https://interop.esante.gouv.fr/ig/fhir/eds/ConceptMap/LabUnit"/>
</parameter>
<parameter>
<valueString value="code"/>
</parameter>
</target>
<target>
<context value="tgtReference"/>
<contextType value="variable"/>
<element value="reference"/>
<transform value="append"/>
<parameter>
<valueString value="Concept/"/>
</parameter>
<parameter>
<valueId value="unitCode"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setUnitSourceValue"/>
<source>
<context value="srcValueQuantity"/>
<element value="code"/>
<variable value="srcValueCode"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="unit_source_value"/>
<transform value="copy"/>
<parameter>
<valueId value="srcValueCode"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setRange"/>
<source>
<context value="src"/>
<element value="referenceRange"/>
<variable value="srcRange"/>
</source>
<rule>
<name value="setRangeLow0"/>
<source>
<context value="srcRange"/>
<element value="low"/>
<variable value="srcRangeLow"/>
</source>
<rule>
<name value="setRangeLow1"/>
<source>
<context value="srcRangeLow"/>
<element value="value"/>
<variable value="srcRangeLowValue"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="range_low"/>
<transform value="copy"/>
<parameter>
<valueId value="srcRangeLowValue"/>
</parameter>
</target>
</rule>
</rule>
<rule>
<name value="setRangeHigh0"/>
<source>
<context value="srcRange"/>
<element value="high"/>
<variable value="srcRangeHigh"/>
</source>
<rule>
<name value="setRangeHigh1"/>
<source>
<context value="srcRangeHigh"/>
<element value="value"/>
<variable value="srcRangeHighValue"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="range_high"/>
<transform value="copy"/>
<parameter>
<valueId value="srcRangeHighValue"/>
</parameter>
</target>
</rule>
</rule>
</rule>
<rule>
<name value="setPerformer"/>
<source>
<context value="src"/>
<element value="performer"/>
<variable value="srcPerformer"/>
</source>
<target>
<context value="tgt"/>
<contextType value="variable"/>
<element value="provider_id"/>
<transform value="copy"/>
<parameter>
<valueId value="srcPerformer"/>
</parameter>
</target>
<documentation
value="reference impropre dans le monde OMOP mais permet d'illustrer l'information qui doit être utilisée pour retrouver le bon OMOPProvider"/>
</rule>
</group>
</StructureMap>