Data Management with FHIR 0.1.0 - ci-build

Data Management with FHIR - version de développement local (intégration continue v0.1.0) construite par les outils de publication FHIR (HL7® FHIR® Standard). Voir le répertoire des versions publiées

## : Alignement de l''expression de besoin vers le modèle physique du DPI dans le cadre de l''usage Core - JSON Representation

Draft as of 2026-04-16

Raw json | Download

    {
      "resourceType" : "StructureMap",
      "id" : "CoreBusiness2Physical",
      "text" : {
        "status" : "generated",
        "div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\"><p class=\"res-header-id\"><b>Narratif généré : StructureMap CoreBusiness2Physical</b></p><a name=\"CoreBusiness2Physical\"> </a><a name=\"hcCoreBusiness2Physical\"> </a><pre class=\"fml\">\r\n<b>map</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureMap/CoreBusiness2Physical<span style=\"color: navy\">&quot; = &quot;</span>CoreBusiness2Physical<span style=\"color: navy\">&quot;\r\n\r\n</span><span style=\"color: navy\">// </span><span style=\"color: green\">Alignement de l''expression de besoin vers le modèle physique du DPI dans le cadre de l''usage Core</span>\r\n\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span><a href=\"http://hl7.org/fhir/R4/questionnaireresponse.html\" title=\"QuestionnaireResponse\">http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse</a><span style=\"color: navy\">&quot; </span><b>alias </b>QR <b>as </b><b>source</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreDataSet<span style=\"color: navy\">&quot; </span><b>alias </b>DataSet <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CorePatient<span style=\"color: navy\">&quot; </span><b>alias </b>PatientTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreAddress<span style=\"color: navy\">&quot; </span><b>alias </b>AddressTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreSejour<span style=\"color: navy\">&quot; </span><b>alias </b>SejourTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreBiology<span style=\"color: navy\">&quot; </span><b>alias </b>BiologyTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreClinical<span style=\"color: navy\">&quot; </span><b>alias </b>ClinicalTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreDiag<span style=\"color: navy\">&quot; </span><b>alias </b>DiagTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreActe<span style=\"color: navy\">&quot; </span><b>alias </b>ActeTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreMedicationAdm<span style=\"color: navy\">&quot; </span><b>alias </b>MedicationAdmTable <b>as </b><b>target</b>\r\n<b>uses</b><span style=\"color: navy\"> &quot;</span>https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreMedicationPre<span style=\"color: navy\">&quot; </span><b>alias </b>MedicationPreTable <b>as </b><b>target</b>\r\n\r\n<b>group </b>init<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">srcQR</span><span style=\"color: navy\"> : </span>QR, <b>target</b> <span style=\"color: maroon\">tgtDS</span><span style=\"color: navy\"> : </span>DataSet<span style=\"color: navy\">)</span><b> &lt;&lt;types&gt;&gt;</b><span style=\"color: navy\"> {\r\n</span>  srcQR<span style=\"color: navy\"><b> -&gt; </b></span>tgtDS.logicalId = <b>uuid</b><span style=\"color: navy\">(</span><span style=\"color: navy\">)</span> <i>&quot;setId&quot;</i><span style=\"color: navy\">;</span>\r\n  srcQR<span style=\"color: navy\"><b> -&gt; </b></span> tgtDS.patient<b> as </b><span style=\"color: maroon\">tgtPatient</span><span style=\"color: navy\">, </span> tgtDS.sejour<b> as </b><span style=\"color: maroon\">tgtSejour</span><span style=\"color: navy\">, </span> tgtDS.biology<b> as </b><span style=\"color: maroon\">tgtBiol</span><span style=\"color: navy\">, </span> tgtDS.clinical<b> as </b><span style=\"color: maroon\">tgtClin</span><span style=\"color: navy\">, </span> tgtDS.medicationPre<b> as </b><span style=\"color: maroon\">tgtMedPre</span><span style=\"color: navy\">, </span> tgtDS.medicationAdm<b> as </b><span style=\"color: maroon\">tgtMedAdm</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    srcQR.subject<b> as </b><span style=\"color: maroon\">srcSubject</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcSubject.identifier<b> as </b><span style=\"color: maroon\">srcSubjectIdentifier</span><b> where </b>system = 'https://dpi.exemple/Patient/PatientNi'<b> then</b><span style=\"color: navy\"> {\r\n</span>        srcSubjectIdentifier.value<b> as </b><span style=\"color: maroon\">srcSubjectId</span><b> then</b><span style=\"color: navy\"> {\r\n</span>          srcQR.item<b> as </b><span style=\"color: maroon\">srcSocioDemoDataItem</span><b> where </b>linkId = '4647259356106'<b> then</b><span style=\"color: navy\"> {\r\n</span>            srcSocioDemoDataItem<span style=\"color: navy\"><b> -&gt; </b></span>tgtDS.patient = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'PatientTable'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">newPatient</span><b> then </b>Patient<span style=\"color: navy\">(</span><span style=\"color: maroon\">srcSubjectId</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">srcSocioDemoDataItem</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">newPatient</span><span style=\"color: navy\">)</span> <i>&quot;setPatient&quot;</i><span style=\"color: navy\">;</span>\r\n            srcSocioDemoDataItem.item<b> as </b><span style=\"color: maroon\">srcEnvItem</span><b> where </b>linkId = '5491974639955'<span style=\"color: navy\"><b> -&gt; </b></span>tgtDS.address = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'AddressTable'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">newAddress</span><b> then </b>Environement<span style=\"color: navy\">(</span><span style=\"color: maroon\">srcSubjectId</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">srcEnvItem</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">newAddress</span><span style=\"color: navy\">)</span> <i>&quot;setEnvironnement&quot;</i><span style=\"color: navy\">;</span>\r\n          <span style=\"color: navy\">}</span> <i>&quot;navigationToSocioDemoData&quot;</i><span style=\"color: navy\">;</span>\r\n          srcQR.item<b> as </b><span style=\"color: maroon\">srcPMSIDataItem</span><b> where </b>linkId = '2825244231605'<b> then</b><span style=\"color: navy\"> {\r\n</span>            srcPMSIDataItem.item<b> as </b><span style=\"color: maroon\">srcPMSISexeItem</span><b> where </b>linkId = '3894630481120'<b> then</b><span style=\"color: navy\"> {\r\n</span>              srcPMSISexeItem.answer<b> as </b><span style=\"color: maroon\">srcPMSISexeAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>                srcPMSISexeAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcPMSISexeValueCoding</span><span style=\"color: navy\"><b> -&gt; </b></span>tgtPatient.gender = <span style=\"color: navy\">(</span>%srcPMSISexeValueCoding.code<span style=\"color: navy\">)</span> <i>&quot;SetPMSISexeValue&quot;</i><span style=\"color: navy\">;</span>\r\n              <span style=\"color: navy\">}</span> <i>&quot;SetPMSISexeAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n            <span style=\"color: navy\">}</span> <i>&quot;setPMSISexe&quot;</i><span style=\"color: navy\">;</span>\r\n            srcPMSIDataItem.item<b> as </b><span style=\"color: maroon\">srcPMSIDiagItem</span><b> where </b>linkId = '9391816419630'<span style=\"color: navy\"><b> -&gt; </b></span>tgtDS.diag = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'DiagTable'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">newDiag</span><b> then </b>PMSIDiag<span style=\"color: navy\">(</span><span style=\"color: maroon\">srcSubjectId</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">srcPMSIDiagItem</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">newDiag</span><span style=\"color: navy\">)</span> <i>&quot;navigationToPMSIDiag&quot;</i><span style=\"color: navy\">;</span>\r\n            srcPMSIDataItem.item<b> as </b><span style=\"color: maroon\">srcPMSIActeItem</span><b> where </b>linkId = '591926901726'<span style=\"color: navy\"><b> -&gt; </b></span>tgtDS.acte = <b>create</b><span style=\"color: navy\">(</span><span style=\"color: blue\">'ActeTable'</span><span style=\"color: navy\">)</span><b> as </b><span style=\"color: maroon\">newActe</span><b> then </b>PMSIActe<span style=\"color: navy\">(</span><span style=\"color: maroon\">srcSubjectId</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">srcPMSIActeItem</span><span style=\"color: navy\">, </span><span style=\"color: maroon\">newActe</span><span style=\"color: navy\">)</span> <i>&quot;navigationToPMSIDiag&quot;</i><span style=\"color: navy\">;</span>\r\n          <span style=\"color: navy\">}</span> <i>&quot;navigationToPMSIData&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: navy\">}</span> <i>&quot;setIdentifierValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;selectPatientIdentifier&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setPatientId&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;setTgtVar&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>Patient<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">srcSubjectId</span>, <b>source</b> <span style=\"color: maroon\">srcSocioDemoDataItem</span>, <b>target</b> <span style=\"color: maroon\">newPatient</span><span style=\"color: navy\"> : </span>PatientTable<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  srcSocioDemoDataItem.item<b> as </b><span style=\"color: maroon\">srcPatientIdItem</span><b> where </b>linkId = '2958000860428'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcNomItem</span><b> where </b>linkId = '8605698058770'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcNomItem.answer<b> as </b><span style=\"color: maroon\">srcNomAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcNomAnswer.value<span style=\"color: navy\"> : </span>string<b> as </b><span style=\"color: maroon\">srcNomValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newPatient.name = <span style=\"color: maroon\">srcNomValue</span> <i>&quot;SetNomValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setNomAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setNom&quot;</i><span style=\"color: navy\">;</span>\r\n    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcPrenomItem</span><b> where </b>linkId = '6214879623503'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPrenomItem.answer<b> as </b><span style=\"color: maroon\">srcPrenomAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcPrenomAnswer.value<span style=\"color: navy\"> : </span>string<b> as </b><span style=\"color: maroon\">srcPrenomValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newPatient.firstName = <span style=\"color: maroon\">srcPrenomValue</span> <i>&quot;SetPrenomValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setPrenomAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setPrenom&quot;</i><span style=\"color: navy\">;</span>\r\n    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcNIRItem</span><b> where </b>linkId = '5711960356160'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcNIRItem.answer<b> as </b><span style=\"color: maroon\">srcNIRAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcNIRAnswer.value<span style=\"color: navy\"> : </span>string<b> as </b><span style=\"color: maroon\">srcNIRValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newPatient.nir = <span style=\"color: maroon\">srcNIRValue</span> <i>&quot;SetNIRValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setNIRAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setNIR&quot;</i><span style=\"color: navy\">;</span>\r\n    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcDDNItem</span><b> where </b>linkId = '5036133558154'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcDDNItem.answer<b> as </b><span style=\"color: maroon\">srcDDNAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcDDNAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcDDNValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newPatient.birthDate = <span style=\"color: maroon\">srcDDNValue</span> <i>&quot;SetDDNValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setDDNAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setDDN&quot;</i><span style=\"color: navy\">;</span>\r\n    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcDDDItem</span><b> where </b>linkId = '5036133558154'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcDDDItem.answer<b> as </b><span style=\"color: maroon\">srcDDDAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcDDDAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcDDDValue</span> <i>&quot;SetDDDValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setDDDAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n      srcDDDItem.item<b> as </b><span style=\"color: maroon\">srcDDDSourceItem</span><b> where </b>linkId = '9098810065693'<b> then</b><span style=\"color: navy\"> {\r\n</span>        srcDDDSourceItem.answer<b> as </b><span style=\"color: maroon\">srcDDDSourceAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>          srcDDDSourceAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcDDDSourceValue</span> <i>&quot;SetDDDSourceValue&quot;</i><span style=\"color: navy\">;</span>\r\n        <span style=\"color: navy\">}</span> <i>&quot;setDDDSourceAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setDDDSource&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setDDD&quot;</i><span style=\"color: navy\">;</span>\r\n    srcPatientIdItem.item<b> as </b><span style=\"color: maroon\">srcGemRankItem</span><b> where </b>linkId = '6931296968515'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcGemRankItem.answer<b> as </b><span style=\"color: maroon\">srcGemRankAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcGemRankAnswer.value<span style=\"color: navy\"> : </span>integer<b> as </b><span style=\"color: maroon\">srcGemRankValue</span> <i>&quot;SetGemRankValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;SetGemRankAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetGemRank&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;navigationToPatientId&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>Environement<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">srcSubjectId</span>, <b>source</b> <span style=\"color: maroon\">srcEnvItem</span>, <b>target</b> <span style=\"color: maroon\">newAddress</span><span style=\"color: navy\"> : </span>AddressTable<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  srcEnvItem.item<b> as </b><span style=\"color: maroon\">srcGeocodItem</span><b> where </b>linkId = '3816475533472'<span style=\"color: navy\"><b> -&gt; </b></span>newAddress.patientNi<b> as </b><span style=\"color: maroon\">newAddressPatient</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    srcGeocodItem<span style=\"color: navy\"><b> -&gt; </b></span>newAddressPatient.reference = <span style=\"color: navy\">(</span>'PatientCore/' + %srcSubjectId.toString()<span style=\"color: navy\">)</span> <i>&quot;setAddressPatientRef&quot;</i><span style=\"color: navy\">;</span>\r\n    srcGeocodItem.item<b> as </b><span style=\"color: maroon\">srcLatItem</span><b> where </b>linkId = '3709843054556'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcLatItem.answer<b> as </b><span style=\"color: maroon\">srcLatAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcLatAnswer.value<span style=\"color: navy\"> : </span>decimal<b> as </b><span style=\"color: maroon\">srcLatValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newAddress.latitude = <span style=\"color: maroon\">srcLatValue</span> <i>&quot;SetLatValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setLatAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setLat&quot;</i><span style=\"color: navy\">;</span>\r\n    srcGeocodItem.item<b> as </b><span style=\"color: maroon\">srcLongItem</span><b> where </b>linkId = '7651448032665'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcLongItem.answer<b> as </b><span style=\"color: maroon\">srcLongAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcLongAnswer.value<span style=\"color: navy\"> : </span>decimal<b> as </b><span style=\"color: maroon\">srcLongValue</span><span style=\"color: navy\"><b> -&gt; </b></span>newAddress.longitude = <span style=\"color: maroon\">srcLongValue</span> <i>&quot;SetLongValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setLongAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setLong&quot;</i><span style=\"color: navy\">;</span>\r\n    srcGeocodItem.item<b> as </b><span style=\"color: maroon\">srcGeocodDateItem</span><b> where </b>linkId = '1185653257776'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcGeocodDateItem.answer<b> as </b><span style=\"color: maroon\">srcGeocodDateAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcGeocodDateAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcGeocodDateValue</span> <i>&quot;SetGeocodDateValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setGeocodDateAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setGeocodDate&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;navigationToGeocod&quot;</i><span style=\"color: navy\">;</span>\r\n  srcEnvItem.item<b> as </b><span style=\"color: maroon\">srcIrisItem</span><b> where </b>linkId = '7621032273792'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcIrisItem.answer<b> as </b><span style=\"color: maroon\">srcIrisAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcIrisAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcIrisValue</span> <i>&quot;SetIrisValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setIrisAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    srcIrisItem.item<b> as </b><span style=\"color: maroon\">srcIrisDateItem</span><b> where </b>linkId = '4999580038872'<b> then</b><span style=\"color: navy\"> {\r\n</span>      srcIrisDateItem.answer<b> as </b><span style=\"color: maroon\">srcIrisDateAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>        srcIrisDateAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcIrisDateValue</span> <i>&quot;SetIrisDateValue&quot;</i><span style=\"color: navy\">;</span>\r\n      <span style=\"color: navy\">}</span> <i>&quot;setIrisDateAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;setIrisDate&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;setIris&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>PMSIDiag<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">srcSubjectId</span>, <b>source</b> <span style=\"color: maroon\">srcPMSIDiagItem</span>, <b>target</b> <span style=\"color: maroon\">newDiag</span><span style=\"color: navy\"> : </span>DiagTable<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  srcPMSIDiagItem<span style=\"color: navy\"><b> -&gt; </b></span>newDiag.patientNi<b> as </b><span style=\"color: maroon\">newDiagPatient</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIDiagItem<span style=\"color: navy\"><b> -&gt; </b></span>newDiagPatient.reference = <span style=\"color: navy\">(</span>'PatientCore/' + %srcSubjectId.toString()<span style=\"color: navy\">)</span> <i>&quot;setDiagPatientRef&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;setDiagPatient&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIDiagItem.item<b> as </b><span style=\"color: maroon\">srcPMSIDiagDateItem</span><b> where </b>linkId = '7114466839467'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIDiagDateItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIDiagDateAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIDiagDateAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcPMSIDiagDateValue</span> <i>&quot;SetPMSIDiagDateValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagDateAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagDate&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIDiagItem.item<b> as </b><span style=\"color: maroon\">srcPMSIDiagTypeItem</span><b> where </b>linkId = '6427586743735'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIDiagTypeItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIDiagTypeAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIDiagTypeAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcPMSIDiagTypeValueCoding</span><span style=\"color: navy\"><b> -&gt; </b></span>newDiag.codeType = <span style=\"color: navy\">(</span>%srcPMSIDiagTypeValueCoding.display<span style=\"color: navy\">)</span> <i>&quot;SetPMSIDiagTypeValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagTypeAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagType&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIDiagItem.item<b> as </b><span style=\"color: maroon\">srcPMSIDiagCodeItem</span><b> where </b>linkId = '5505101189372'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIDiagCodeItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIDiagCodeAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIDiagCodeAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcPMSIDiagCodeValueCoding</span><span style=\"color: navy\"><b> -&gt; </b></span>newDiag.code = <span style=\"color: navy\">(</span>%srcPMSIDiagCodeValueCoding.code<span style=\"color: navy\">)</span> <i>&quot;SetPMSIDiagCodeValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagCodeAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIDiagCode&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span><b>group </b>PMSIActe<span style=\"color: navy\">(</span><b>source</b> <span style=\"color: maroon\">srcSubjectId</span>, <b>source</b> <span style=\"color: maroon\">srcPMSIActeItem</span>, <b>target</b> <span style=\"color: maroon\">newActe</span><span style=\"color: navy\"> : </span>ActeTable<span style=\"color: navy\">)</span><span style=\"color: navy\"> {\r\n</span>  srcPMSIActeItem<span style=\"color: navy\"><b> -&gt; </b></span>newActe.patientNi<b> as </b><span style=\"color: maroon\">newActePatient</span><b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIActeItem<span style=\"color: navy\"><b> -&gt; </b></span>newActePatient.reference = <span style=\"color: navy\">(</span>'PatientCore/' + %srcSubjectId.toString()<span style=\"color: navy\">)</span> <i>&quot;setActePatientRef&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;setActePatient&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIActeItem.item<b> as </b><span style=\"color: maroon\">srcPMSIActeDateRecItem</span><b> where </b>linkId = '9436509453137'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIActeDateRecItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIActeDateRecAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIActeDateRecAnswer.value<span style=\"color: navy\"> : </span>date<b> as </b><span style=\"color: maroon\">srcPMSIActeDateRecValue</span> <i>&quot;SetPMSIActeDateRecValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeDateRecAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeDateRec&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIActeItem.item<b> as </b><span style=\"color: maroon\">srcPMSIActeDateItem</span><b> where </b>linkId = '5066866286682'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIActeDateItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIActeDateAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIActeDateAnswer.value<span style=\"color: navy\"> : </span>dateTime<b> as </b><span style=\"color: maroon\">srcPMSIActeDateValue</span><span style=\"color: navy\"><b> -&gt; </b></span> newActe.dateStart = <span style=\"color: maroon\">srcPMSIActeDateValue</span><span style=\"color: navy\">, </span> newActe.dateEnd = <span style=\"color: maroon\">srcPMSIActeDateValue</span> <i>&quot;SetPMSIActeDateValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeDateAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeDate&quot;</i><span style=\"color: navy\">;</span>\r\n  srcPMSIActeItem.item<b> as </b><span style=\"color: maroon\">srcPMSIActeCodeItem</span><b> where </b>linkId = '7758110033600'<b> then</b><span style=\"color: navy\"> {\r\n</span>    srcPMSIActeCodeItem.answer<b> as </b><span style=\"color: maroon\">srcPMSIActeCodeAnswer</span><b> then</b><span style=\"color: navy\"> {\r\n</span>      srcPMSIActeCodeAnswer.value<span style=\"color: navy\"> : </span>Coding<b> as </b><span style=\"color: maroon\">srcPMSIActeCodeValueCoding</span><span style=\"color: navy\"><b> -&gt; </b></span>newActe.code = <span style=\"color: navy\">(</span>%srcPMSIActeCodeValueCoding.code<span style=\"color: navy\">)</span> <i>&quot;SetPMSIActeCodeValue&quot;</i><span style=\"color: navy\">;</span>\r\n    <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeCodeAnswer&quot;</i><span style=\"color: navy\">;</span>\r\n  <span style=\"color: navy\">}</span> <i>&quot;SetPMSIActeCode&quot;</i><span style=\"color: navy\">;</span>\r\n<span style=\"color: navy\">}\r\n\r\n</span></pre></div>"
      },
      "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureMap/CoreBusiness2Physical",
      "version" : "0.1.0",
      "name" : "CoreBusiness2Physical",
      "title" : "Alignement de l''expression de besoin vers le modèle physique du DPI dans le cadre de l''usage Core",
      "status" : "draft",
      "date" : "2026-04-16T14:35:38+00:00",
      "publisher" : "AP-HP",
      "contact" : [
        {
          "name" : "AP-HP",
          "telecom" : [
            {
              "system" : "url",
              "value" : "https://aphp.fr"
            }
          ]
        }
      ],
      "description" : "Alignement de l''expression de besoin vers le modèle physique du DPI dans le cadre de l''usage Core",
      "jurisdiction" : [
        {
          "coding" : [
            {
              "system" : "urn:iso:std:iso:3166",
              "code" : "FR"
            }
          ]
        }
      ],
      "structure" : [
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse",
          "mode" : "source",
          "alias" : "QR"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreDataSet",
          "mode" : "target",
          "alias" : "DataSet"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CorePatient",
          "mode" : "target",
          "alias" : "PatientTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreAddress",
          "mode" : "target",
          "alias" : "AddressTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreSejour",
          "mode" : "target",
          "alias" : "SejourTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreBiology",
          "mode" : "target",
          "alias" : "BiologyTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreClinical",
          "mode" : "target",
          "alias" : "ClinicalTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreDiag",
          "mode" : "target",
          "alias" : "DiagTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreActe",
          "mode" : "target",
          "alias" : "ActeTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreMedicationAdm",
          "mode" : "target",
          "alias" : "MedicationAdmTable"
        },
        {
          "url" : "https://interop.aphp.fr/ig/fhir/dm/StructureDefinition/CoreMedicationPre",
          "mode" : "target",
          "alias" : "MedicationPreTable"
        }
      ],
      "group" : [
        {
          "name" : "init",
          "typeMode" : "types",
          "input" : [
            {
              "name" : "srcQR",
              "type" : "QR",
              "mode" : "source"
            },
            {
              "name" : "tgtDS",
              "type" : "DataSet",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "setId",
              "source" : [
                {
                  "context" : "srcQR"
                }
              ],
              "target" : [
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "logicalId",
                  "transform" : "uuid"
                }
              ]
            },
            {
              "name" : "setTgtVar",
              "source" : [
                {
                  "context" : "srcQR"
                }
              ],
              "target" : [
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "patient",
                  "variable" : "tgtPatient"
                },
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "sejour",
                  "variable" : "tgtSejour"
                },
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "biology",
                  "variable" : "tgtBiol"
                },
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "clinical",
                  "variable" : "tgtClin"
                },
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "medicationPre",
                  "variable" : "tgtMedPre"
                },
                {
                  "context" : "tgtDS",
                  "contextType" : "variable",
                  "element" : "medicationAdm",
                  "variable" : "tgtMedAdm"
                }
              ],
              "rule" : [
                {
                  "name" : "setPatientId",
                  "source" : [
                    {
                      "context" : "srcQR",
                      "element" : "subject",
                      "variable" : "srcSubject"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "selectPatientIdentifier",
                      "source" : [
                        {
                          "context" : "srcSubject",
                          "element" : "identifier",
                          "variable" : "srcSubjectIdentifier",
                          "condition" : "system = 'https://dpi.exemple/Patient/PatientNi'"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "setIdentifierValue",
                          "source" : [
                            {
                              "context" : "srcSubjectIdentifier",
                              "element" : "value",
                              "variable" : "srcSubjectId"
                            }
                          ],
                          "rule" : [
                            {
                              "name" : "navigationToSocioDemoData",
                              "source" : [
                                {
                                  "context" : "srcQR",
                                  "element" : "item",
                                  "variable" : "srcSocioDemoDataItem",
                                  "condition" : "linkId = '4647259356106'"
                                }
                              ],
                              "rule" : [
                                {
                                  "name" : "setPatient",
                                  "source" : [
                                    {
                                      "context" : "srcSocioDemoDataItem"
                                    }
                                  ],
                                  "target" : [
                                    {
                                      "context" : "tgtDS",
                                      "contextType" : "variable",
                                      "element" : "patient",
                                      "variable" : "newPatient",
                                      "transform" : "create",
                                      "parameter" : [
                                        {
                                          "valueString" : "PatientTable"
                                        }
                                      ]
                                    }
                                  ],
                                  "dependent" : [
                                    {
                                      "name" : "Patient",
                                      "variable" : [
                                        "srcSubjectId",
                                        "srcSocioDemoDataItem",
                                        "newPatient"
                                      ]
                                    }
                                  ]
                                },
                                {
                                  "name" : "setEnvironnement",
                                  "source" : [
                                    {
                                      "context" : "srcSocioDemoDataItem",
                                      "element" : "item",
                                      "variable" : "srcEnvItem",
                                      "condition" : "linkId = '5491974639955'"
                                    }
                                  ],
                                  "target" : [
                                    {
                                      "context" : "tgtDS",
                                      "contextType" : "variable",
                                      "element" : "address",
                                      "variable" : "newAddress",
                                      "transform" : "create",
                                      "parameter" : [
                                        {
                                          "valueString" : "AddressTable"
                                        }
                                      ]
                                    }
                                  ],
                                  "dependent" : [
                                    {
                                      "name" : "Environement",
                                      "variable" : [
                                        "srcSubjectId",
                                        "srcEnvItem",
                                        "newAddress"
                                      ]
                                    }
                                  ]
                                }
                              ]
                            },
                            {
                              "name" : "navigationToPMSIData",
                              "source" : [
                                {
                                  "context" : "srcQR",
                                  "element" : "item",
                                  "variable" : "srcPMSIDataItem",
                                  "condition" : "linkId = '2825244231605'"
                                }
                              ],
                              "rule" : [
                                {
                                  "name" : "setPMSISexe",
                                  "source" : [
                                    {
                                      "context" : "srcPMSIDataItem",
                                      "element" : "item",
                                      "variable" : "srcPMSISexeItem",
                                      "condition" : "linkId = '3894630481120'"
                                    }
                                  ],
                                  "rule" : [
                                    {
                                      "name" : "SetPMSISexeAnswer",
                                      "source" : [
                                        {
                                          "context" : "srcPMSISexeItem",
                                          "element" : "answer",
                                          "variable" : "srcPMSISexeAnswer"
                                        }
                                      ],
                                      "rule" : [
                                        {
                                          "name" : "SetPMSISexeValue",
                                          "source" : [
                                            {
                                              "context" : "srcPMSISexeAnswer",
                                              "type" : "Coding",
                                              "element" : "value",
                                              "variable" : "srcPMSISexeValueCoding"
                                            }
                                          ],
                                          "target" : [
                                            {
                                              "context" : "tgtPatient",
                                              "contextType" : "variable",
                                              "element" : "gender",
                                              "transform" : "evaluate",
                                              "parameter" : [
                                                {
                                                  "valueString" : "%srcPMSISexeValueCoding.code"
                                                }
                                              ]
                                            }
                                          ]
                                        }
                                      ]
                                    }
                                  ]
                                },
                                {
                                  "name" : "navigationToPMSIDiag",
                                  "source" : [
                                    {
                                      "context" : "srcPMSIDataItem",
                                      "element" : "item",
                                      "variable" : "srcPMSIDiagItem",
                                      "condition" : "linkId = '9391816419630'"
                                    }
                                  ],
                                  "target" : [
                                    {
                                      "context" : "tgtDS",
                                      "contextType" : "variable",
                                      "element" : "diag",
                                      "variable" : "newDiag",
                                      "transform" : "create",
                                      "parameter" : [
                                        {
                                          "valueString" : "DiagTable"
                                        }
                                      ]
                                    }
                                  ],
                                  "dependent" : [
                                    {
                                      "name" : "PMSIDiag",
                                      "variable" : [
                                        "srcSubjectId",
                                        "srcPMSIDiagItem",
                                        "newDiag"
                                      ]
                                    }
                                  ]
                                },
                                {
                                  "name" : "navigationToPMSIDiag",
                                  "source" : [
                                    {
                                      "context" : "srcPMSIDataItem",
                                      "element" : "item",
                                      "variable" : "srcPMSIActeItem",
                                      "condition" : "linkId = '591926901726'"
                                    }
                                  ],
                                  "target" : [
                                    {
                                      "context" : "tgtDS",
                                      "contextType" : "variable",
                                      "element" : "acte",
                                      "variable" : "newActe",
                                      "transform" : "create",
                                      "parameter" : [
                                        {
                                          "valueString" : "ActeTable"
                                        }
                                      ]
                                    }
                                  ],
                                  "dependent" : [
                                    {
                                      "name" : "PMSIActe",
                                      "variable" : [
                                        "srcSubjectId",
                                        "srcPMSIActeItem",
                                        "newActe"
                                      ]
                                    }
                                  ]
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "Patient",
          "typeMode" : "none",
          "input" : [
            {
              "name" : "srcSubjectId",
              "mode" : "source"
            },
            {
              "name" : "srcSocioDemoDataItem",
              "mode" : "source"
            },
            {
              "name" : "newPatient",
              "type" : "PatientTable",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "navigationToPatientId",
              "source" : [
                {
                  "context" : "srcSocioDemoDataItem",
                  "element" : "item",
                  "variable" : "srcPatientIdItem",
                  "condition" : "linkId = '2958000860428'"
                }
              ],
              "rule" : [
                {
                  "name" : "setNom",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcNomItem",
                      "condition" : "linkId = '8605698058770'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setNomAnswer",
                      "source" : [
                        {
                          "context" : "srcNomItem",
                          "element" : "answer",
                          "variable" : "srcNomAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetNomValue",
                          "source" : [
                            {
                              "context" : "srcNomAnswer",
                              "type" : "string",
                              "element" : "value",
                              "variable" : "srcNomValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newPatient",
                              "contextType" : "variable",
                              "element" : "name",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcNomValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setPrenom",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcPrenomItem",
                      "condition" : "linkId = '6214879623503'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setPrenomAnswer",
                      "source" : [
                        {
                          "context" : "srcPrenomItem",
                          "element" : "answer",
                          "variable" : "srcPrenomAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetPrenomValue",
                          "source" : [
                            {
                              "context" : "srcPrenomAnswer",
                              "type" : "string",
                              "element" : "value",
                              "variable" : "srcPrenomValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newPatient",
                              "contextType" : "variable",
                              "element" : "firstName",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcPrenomValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setNIR",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcNIRItem",
                      "condition" : "linkId = '5711960356160'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setNIRAnswer",
                      "source" : [
                        {
                          "context" : "srcNIRItem",
                          "element" : "answer",
                          "variable" : "srcNIRAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetNIRValue",
                          "source" : [
                            {
                              "context" : "srcNIRAnswer",
                              "type" : "string",
                              "element" : "value",
                              "variable" : "srcNIRValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newPatient",
                              "contextType" : "variable",
                              "element" : "nir",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcNIRValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setDDN",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcDDNItem",
                      "condition" : "linkId = '5036133558154'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setDDNAnswer",
                      "source" : [
                        {
                          "context" : "srcDDNItem",
                          "element" : "answer",
                          "variable" : "srcDDNAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetDDNValue",
                          "source" : [
                            {
                              "context" : "srcDDNAnswer",
                              "type" : "date",
                              "element" : "value",
                              "variable" : "srcDDNValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newPatient",
                              "contextType" : "variable",
                              "element" : "birthDate",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcDDNValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setDDD",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcDDDItem",
                      "condition" : "linkId = '5036133558154'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setDDDAnswer",
                      "source" : [
                        {
                          "context" : "srcDDDItem",
                          "element" : "answer",
                          "variable" : "srcDDDAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetDDDValue",
                          "source" : [
                            {
                              "context" : "srcDDDAnswer",
                              "type" : "date",
                              "element" : "value",
                              "variable" : "srcDDDValue"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name" : "setDDDSource",
                      "source" : [
                        {
                          "context" : "srcDDDItem",
                          "element" : "item",
                          "variable" : "srcDDDSourceItem",
                          "condition" : "linkId = '9098810065693'"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "setDDDSourceAnswer",
                          "source" : [
                            {
                              "context" : "srcDDDSourceItem",
                              "element" : "answer",
                              "variable" : "srcDDDSourceAnswer"
                            }
                          ],
                          "rule" : [
                            {
                              "name" : "SetDDDSourceValue",
                              "source" : [
                                {
                                  "context" : "srcDDDSourceAnswer",
                                  "type" : "Coding",
                                  "element" : "value",
                                  "variable" : "srcDDDSourceValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "SetGemRank",
                  "source" : [
                    {
                      "context" : "srcPatientIdItem",
                      "element" : "item",
                      "variable" : "srcGemRankItem",
                      "condition" : "linkId = '6931296968515'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetGemRankAnswer",
                      "source" : [
                        {
                          "context" : "srcGemRankItem",
                          "element" : "answer",
                          "variable" : "srcGemRankAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetGemRankValue",
                          "source" : [
                            {
                              "context" : "srcGemRankAnswer",
                              "type" : "integer",
                              "element" : "value",
                              "variable" : "srcGemRankValue"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "Environement",
          "typeMode" : "none",
          "input" : [
            {
              "name" : "srcSubjectId",
              "mode" : "source"
            },
            {
              "name" : "srcEnvItem",
              "mode" : "source"
            },
            {
              "name" : "newAddress",
              "type" : "AddressTable",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "navigationToGeocod",
              "source" : [
                {
                  "context" : "srcEnvItem",
                  "element" : "item",
                  "variable" : "srcGeocodItem",
                  "condition" : "linkId = '3816475533472'"
                }
              ],
              "target" : [
                {
                  "context" : "newAddress",
                  "contextType" : "variable",
                  "element" : "patientNi",
                  "variable" : "newAddressPatient"
                }
              ],
              "rule" : [
                {
                  "name" : "setAddressPatientRef",
                  "source" : [
                    {
                      "context" : "srcGeocodItem"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "newAddressPatient",
                      "contextType" : "variable",
                      "element" : "reference",
                      "transform" : "evaluate",
                      "parameter" : [
                        {
                          "valueString" : "'PatientCore/' + %srcSubjectId.toString()"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setLat",
                  "source" : [
                    {
                      "context" : "srcGeocodItem",
                      "element" : "item",
                      "variable" : "srcLatItem",
                      "condition" : "linkId = '3709843054556'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setLatAnswer",
                      "source" : [
                        {
                          "context" : "srcLatItem",
                          "element" : "answer",
                          "variable" : "srcLatAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetLatValue",
                          "source" : [
                            {
                              "context" : "srcLatAnswer",
                              "type" : "decimal",
                              "element" : "value",
                              "variable" : "srcLatValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newAddress",
                              "contextType" : "variable",
                              "element" : "latitude",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcLatValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setLong",
                  "source" : [
                    {
                      "context" : "srcGeocodItem",
                      "element" : "item",
                      "variable" : "srcLongItem",
                      "condition" : "linkId = '7651448032665'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setLongAnswer",
                      "source" : [
                        {
                          "context" : "srcLongItem",
                          "element" : "answer",
                          "variable" : "srcLongAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetLongValue",
                          "source" : [
                            {
                              "context" : "srcLongAnswer",
                              "type" : "decimal",
                              "element" : "value",
                              "variable" : "srcLongValue"
                            }
                          ],
                          "target" : [
                            {
                              "context" : "newAddress",
                              "contextType" : "variable",
                              "element" : "longitude",
                              "transform" : "copy",
                              "parameter" : [
                                {
                                  "valueId" : "srcLongValue"
                                }
                              ]
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setGeocodDate",
                  "source" : [
                    {
                      "context" : "srcGeocodItem",
                      "element" : "item",
                      "variable" : "srcGeocodDateItem",
                      "condition" : "linkId = '1185653257776'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setGeocodDateAnswer",
                      "source" : [
                        {
                          "context" : "srcGeocodDateItem",
                          "element" : "answer",
                          "variable" : "srcGeocodDateAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetGeocodDateValue",
                          "source" : [
                            {
                              "context" : "srcGeocodDateAnswer",
                              "type" : "date",
                              "element" : "value",
                              "variable" : "srcGeocodDateValue"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "setIris",
              "source" : [
                {
                  "context" : "srcEnvItem",
                  "element" : "item",
                  "variable" : "srcIrisItem",
                  "condition" : "linkId = '7621032273792'"
                }
              ],
              "rule" : [
                {
                  "name" : "setIrisAnswer",
                  "source" : [
                    {
                      "context" : "srcIrisItem",
                      "element" : "answer",
                      "variable" : "srcIrisAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetIrisValue",
                      "source" : [
                        {
                          "context" : "srcIrisAnswer",
                          "type" : "Coding",
                          "element" : "value",
                          "variable" : "srcIrisValue"
                        }
                      ]
                    }
                  ]
                },
                {
                  "name" : "setIrisDate",
                  "source" : [
                    {
                      "context" : "srcIrisItem",
                      "element" : "item",
                      "variable" : "srcIrisDateItem",
                      "condition" : "linkId = '4999580038872'"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "setIrisDateAnswer",
                      "source" : [
                        {
                          "context" : "srcIrisDateItem",
                          "element" : "answer",
                          "variable" : "srcIrisDateAnswer"
                        }
                      ],
                      "rule" : [
                        {
                          "name" : "SetIrisDateValue",
                          "source" : [
                            {
                              "context" : "srcIrisDateAnswer",
                              "type" : "date",
                              "element" : "value",
                              "variable" : "srcIrisDateValue"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "PMSIDiag",
          "typeMode" : "none",
          "input" : [
            {
              "name" : "srcSubjectId",
              "mode" : "source"
            },
            {
              "name" : "srcPMSIDiagItem",
              "mode" : "source"
            },
            {
              "name" : "newDiag",
              "type" : "DiagTable",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "setDiagPatient",
              "source" : [
                {
                  "context" : "srcPMSIDiagItem"
                }
              ],
              "target" : [
                {
                  "context" : "newDiag",
                  "contextType" : "variable",
                  "element" : "patientNi",
                  "variable" : "newDiagPatient"
                }
              ],
              "rule" : [
                {
                  "name" : "setDiagPatientRef",
                  "source" : [
                    {
                      "context" : "srcPMSIDiagItem"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "newDiagPatient",
                      "contextType" : "variable",
                      "element" : "reference",
                      "transform" : "evaluate",
                      "parameter" : [
                        {
                          "valueString" : "'PatientCore/' + %srcSubjectId.toString()"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIDiagDate",
              "source" : [
                {
                  "context" : "srcPMSIDiagItem",
                  "element" : "item",
                  "variable" : "srcPMSIDiagDateItem",
                  "condition" : "linkId = '7114466839467'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIDiagDateAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIDiagDateItem",
                      "element" : "answer",
                      "variable" : "srcPMSIDiagDateAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIDiagDateValue",
                      "source" : [
                        {
                          "context" : "srcPMSIDiagDateAnswer",
                          "type" : "date",
                          "element" : "value",
                          "variable" : "srcPMSIDiagDateValue"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIDiagType",
              "source" : [
                {
                  "context" : "srcPMSIDiagItem",
                  "element" : "item",
                  "variable" : "srcPMSIDiagTypeItem",
                  "condition" : "linkId = '6427586743735'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIDiagTypeAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIDiagTypeItem",
                      "element" : "answer",
                      "variable" : "srcPMSIDiagTypeAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIDiagTypeValue",
                      "source" : [
                        {
                          "context" : "srcPMSIDiagTypeAnswer",
                          "type" : "Coding",
                          "element" : "value",
                          "variable" : "srcPMSIDiagTypeValueCoding"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "newDiag",
                          "contextType" : "variable",
                          "element" : "codeType",
                          "transform" : "evaluate",
                          "parameter" : [
                            {
                              "valueString" : "%srcPMSIDiagTypeValueCoding.display"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIDiagCode",
              "source" : [
                {
                  "context" : "srcPMSIDiagItem",
                  "element" : "item",
                  "variable" : "srcPMSIDiagCodeItem",
                  "condition" : "linkId = '5505101189372'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIDiagCodeAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIDiagCodeItem",
                      "element" : "answer",
                      "variable" : "srcPMSIDiagCodeAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIDiagCodeValue",
                      "source" : [
                        {
                          "context" : "srcPMSIDiagCodeAnswer",
                          "type" : "Coding",
                          "element" : "value",
                          "variable" : "srcPMSIDiagCodeValueCoding"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "newDiag",
                          "contextType" : "variable",
                          "element" : "code",
                          "transform" : "evaluate",
                          "parameter" : [
                            {
                              "valueString" : "%srcPMSIDiagCodeValueCoding.code"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        },
        {
          "name" : "PMSIActe",
          "typeMode" : "none",
          "input" : [
            {
              "name" : "srcSubjectId",
              "mode" : "source"
            },
            {
              "name" : "srcPMSIActeItem",
              "mode" : "source"
            },
            {
              "name" : "newActe",
              "type" : "ActeTable",
              "mode" : "target"
            }
          ],
          "rule" : [
            {
              "name" : "setActePatient",
              "source" : [
                {
                  "context" : "srcPMSIActeItem"
                }
              ],
              "target" : [
                {
                  "context" : "newActe",
                  "contextType" : "variable",
                  "element" : "patientNi",
                  "variable" : "newActePatient"
                }
              ],
              "rule" : [
                {
                  "name" : "setActePatientRef",
                  "source" : [
                    {
                      "context" : "srcPMSIActeItem"
                    }
                  ],
                  "target" : [
                    {
                      "context" : "newActePatient",
                      "contextType" : "variable",
                      "element" : "reference",
                      "transform" : "evaluate",
                      "parameter" : [
                        {
                          "valueString" : "'PatientCore/' + %srcSubjectId.toString()"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIActeDateRec",
              "source" : [
                {
                  "context" : "srcPMSIActeItem",
                  "element" : "item",
                  "variable" : "srcPMSIActeDateRecItem",
                  "condition" : "linkId = '9436509453137'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIActeDateRecAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIActeDateRecItem",
                      "element" : "answer",
                      "variable" : "srcPMSIActeDateRecAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIActeDateRecValue",
                      "source" : [
                        {
                          "context" : "srcPMSIActeDateRecAnswer",
                          "type" : "date",
                          "element" : "value",
                          "variable" : "srcPMSIActeDateRecValue"
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIActeDate",
              "source" : [
                {
                  "context" : "srcPMSIActeItem",
                  "element" : "item",
                  "variable" : "srcPMSIActeDateItem",
                  "condition" : "linkId = '5066866286682'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIActeDateAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIActeDateItem",
                      "element" : "answer",
                      "variable" : "srcPMSIActeDateAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIActeDateValue",
                      "source" : [
                        {
                          "context" : "srcPMSIActeDateAnswer",
                          "type" : "dateTime",
                          "element" : "value",
                          "variable" : "srcPMSIActeDateValue"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "newActe",
                          "contextType" : "variable",
                          "element" : "dateStart",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "srcPMSIActeDateValue"
                            }
                          ]
                        },
                        {
                          "context" : "newActe",
                          "contextType" : "variable",
                          "element" : "dateEnd",
                          "transform" : "copy",
                          "parameter" : [
                            {
                              "valueId" : "srcPMSIActeDateValue"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            },
            {
              "name" : "SetPMSIActeCode",
              "source" : [
                {
                  "context" : "srcPMSIActeItem",
                  "element" : "item",
                  "variable" : "srcPMSIActeCodeItem",
                  "condition" : "linkId = '7758110033600'"
                }
              ],
              "rule" : [
                {
                  "name" : "SetPMSIActeCodeAnswer",
                  "source" : [
                    {
                      "context" : "srcPMSIActeCodeItem",
                      "element" : "answer",
                      "variable" : "srcPMSIActeCodeAnswer"
                    }
                  ],
                  "rule" : [
                    {
                      "name" : "SetPMSIActeCodeValue",
                      "source" : [
                        {
                          "context" : "srcPMSIActeCodeAnswer",
                          "type" : "Coding",
                          "element" : "value",
                          "variable" : "srcPMSIActeCodeValueCoding"
                        }
                      ],
                      "target" : [
                        {
                          "context" : "newActe",
                          "contextType" : "variable",
                          "element" : "code",
                          "transform" : "evaluate",
                          "parameter" : [
                            {
                              "valueString" : "%srcPMSIActeCodeValueCoding.code"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                }
              ]
            }
          ]
        }
      ]
    }