CDA to FHIR Maps, published by HL7 Italy. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/hl7-it/cda2fhir/ and changes regularly. See the Directory of published versions
Draft as of 2024-09-15 |
@prefix fhir: <http://hl7.org/fhir/> . @prefix owl: <http://www.w3.org/2002/07/owl#> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . @prefix xsd: <http://www.w3.org/2001/XMLSchema#> . # - resource ------------------------------------------------------------------- a fhir:StructureMap ; fhir:nodeRole fhir:treeRoot ; fhir:id [ fhir:v "cda2fhirAmbReport"] ; # fhir:text [ fhir:status [ fhir:v "generated" ] ; fhir:div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n <pre>map "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirAmbReport" = "cda2fhirAmbReport"\n\nuses "http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument" alias ClinicalDocument as source\nuses "http://hl7.org/fhir/cda/StructureDefinition/AssignedAuthor" alias AssignedAuthor as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/AssignedEntity" alias AssignedEntity as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/AssociatedEntity" alias AssociatedEntity as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/CustodianOrganization" alias CustodianOrganization as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/OrganizationPartOf" alias OrganizationPartOf as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/Organization" alias rapresentedOrganization as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/Section" alias Section as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/PatientRole" alias PatientRole as queried\nuses "http://hl7.org/fhir/cda/StructureDefinition/AD" alias AD as source\nuses "http://hl7.org/fhir/StructureDefinition/Bundle" alias Bundle as target\nuses "http://hl7.org/fhir/StructureDefinition/Composition" alias Composition as produced\nuses "http://hl7.org/fhir/StructureDefinition/Patient" alias Patient as produced\nuses "http://hl7.org/fhir/StructureDefinition/Encounter" alias Encounter as produced\nuses "http://hl7.org/fhir/StructureDefinition/Person" alias Patient as produced\nuses "http://hl7.org/fhir/StructureDefinition/List" alias List as produced\nuses "http://hl7.org/fhir/StructureDefinition/Practitioner" alias Practitioner as produced\nuses "http://hl7.org/fhir/StructureDefinition/Organization" alias Organization as produced\nuses "http://hl7.org/fhir/cda/StructureDefinition/Act" alias Act as produced\nuses "http://hl7.org/fhir/cda/StructureDefinition/IVL-PQ" alias IVL_PQ as source\nuses "http://hl7.org/fhir/cda/StructureDefinition/PQ" alias PQ as source\nuses "http://hl7.org/fhir/StructureDefinition/SimpleQuantity" alias SimpleQuantity as target\n\nimports "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirDataTypes"\nimports "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirHeader"\n\ngroup CdaToBundle(source cda : ClinicalDocument, target bundle : Bundle) {\n cda -> bundle.entry as e, e.request = create('BackboneElement') as request, request.method = 'POST', e.resource = create('Composition') as composition, composition.id = uuid() as uuid1, e.fullUrl = append('https://example/Composition/', uuid1), request.url = 'Composition', bundle.entry as e2, e2.request = create('BackboneElement') as requestPAT, requestPAT.method = 'PUT', e2.resource = create('Patient') as patient, patient.id = uuid() as uuid2, e2.fullUrl = append('https://example/Patient/', uuid2), bundle.entry as e3, e3.request = create('BackboneElement') as request, request.method = 'POST', e3.resource = create('Encounter') as encounter, encounter.id = uuid() as uuid3, e3.fullUrl = append('https://example/Encounter/', uuid3), request.url = 'Encounter', bundle.entry as e4, e4.request = create('BackboneElement') as request, request.method = 'POST', e4.resource = create('DocumentReference') as DocumentReference, DocumentReference.id = uuid() as uuid4, e4.fullUrl = append('https://example/DocumentReference/', uuid4), request.url = 'DocumentReference' then {\n cda then ClinicalDocumentToBundle(cda, patient, composition, encounter, bundle, DocumentReference) "cdatobundle";\n cda.recordTarget as recordTarget then {\n recordTarget.patientRole as patient then {\n patient.id as id -> patient.identifier as identifier then {\n id.root as r -> identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') "root1";\n id.extension as ext1 -> identifier.value = ext1 "value";\n id.assigningAuthorityName as s -> identifier.assigner as a, a.display = s;\n } "idfr";\n patient.id as id where (root = '2.16.840.1.113883.2.9.4.3.2') or (root = '2.16.840.1.113883.2.9.4.3.7') or (root = '2.16.840.1.113883.2.9.4.3.3') or (root = '2.16.840.1.113883.2.9.4.3.17') or (root = '2.16.840.1.113883.2.9.4.3.18') or (root = '2.16.840.1.113883.2.9.2.10.4.1.1') or (root = '2.16.840.1.113883.2.9.2.20.4.1.1') or (root = '2.16.840.1.113883.2.9.2.30.4.1.1') or (root = '2.16.840.1.113883.2.9.2.41.4.1.1') or (root = '2.16.840.1.113883.2.9.2.42.4.1.1') or (root = '2.16.840.1.113883.2.9.2.50.4.1.1') or (root = '2.16.840.1.113883.2.9.2.60.4.1.1') or (root = '2.16.840.1.113883.2.9.2.70.4.1.1') or (root = '2.16.840.1.113883.2.9.2.80.4.1.1') or (root = '2.16.840.1.113883.2.9.2.90.4.1.1') or (root = '2.16.840.1.113883.2.9.2.100.4.1.1') or (root = '2.16.840.1.113883.2.9.2.110.4.1.1') or (root = '2.16.840.1.113883.2.9.2.120.4.1.1') or (root = '2.16.840.1.113883.2.9.2.130.4.1.1') or (root = '2.16.840.1.113883.2.9.2.140.4.1.1') or (root = '2.16.840.1.113883.2.9.2.150.4.1.1') or (root = '2.16.840.1.113883.2.9.2.160.4.1.1') or (root = '2.16.840.1.113883.2.9.2.170.4.1.1') or (root = '2.16.840.1.113883.2.9.2.180.4.1.1') or (root = '2.16.840.1.113883.2.9.2.190.4.1.1') or (root = '2.16.840.1.113883.2.9.2.200.4.1.1') or (root = '2.16.840.1.113883.2.9.2.10.4.1') or (root = '2.16.840.1.113883.2.9.2.20.4.1') or (root = '2.16.840.1.113883.2.9.2.30.4.1') or (root = '2.16.840.1.113883.2.9.2.41.4.1') or (root = '2.16.840.1.113883.2.9.2.42.4.1') or (root = '2.16.840.1.113883.2.9.2.50.4.1') or (root = '2.16.840.1.113883.2.9.2.60.4.1') or (root = '2.16.840.1.113883.2.9.2.70.4.1') or (root = '2.16.840.1.113883.2.9.2.80.4.1') or (root = '2.16.840.1.113883.2.9.2.90.4.1') or (root = '2.16.840.1.113883.2.9.2.100.4.1') or (root = '2.16.840.1.113883.2.9.2.110.4.1') or (root = '2.16.840.1.113883.2.9.2.120.4.1') or (root = '2.16.840.1.113883.2.9.2.130.4.1') or (root = '2.16.840.1.113883.2.9.2.140.4.1') or (root = '2.16.840.1.113883.2.9.2.150.4.1') or (root = '2.16.840.1.113883.2.9.2.160.4.1') or (root = '2.16.840.1.113883.2.9.2.170.4.1') or (root = '2.16.840.1.113883.2.9.2.180.4.1') or (root = '2.16.840.1.113883.2.9.2.190.4.1') or (root = '2.16.840.1.113883.2.9.2.200.4.1') or (root = '2.16.840.1.113883.2.9.4.3.15') then {\n id.extension as ext -> requestPAT.url = append('Patient?identifier=', ext) "UUID";\n } "record";\n } "recPat";\n } "patient";\n } "ClinicalDocumentToBody";\n}\n\ngroup ClinicalDocumentToBundle(source cda : ClinicalDocument, target patient : Patient, target composition : Composition, target encounter : Encounter, target bundle : Bundle, target DocumentReference : DocumentReference) {\n cda -> bundle.id = uuid() "id";\n cda.id -> bundle.identifier "identifier";\n cda -> bundle.type = 'transaction' "type";\n cda -> bundle.timestamp = (timestamp.now()) "date";\n cda then ClinicalDocumentComposition(cda, composition, patient, encounter, bundle, DocumentReference) "composition";\n cda -> bundle.entry as e, e.request = create('BackboneElement') as request, request.method = 'POST', e.resource = create('DiagnosticReport') as diagnosticReport, diagnosticReport.id = uuid() as uuid1, e.fullUrl = append('https://example/DiagnosticReport/', uuid1), request.url = 'DiagnosticReport' then {\n cda.code -> diagnosticReport.code "diagnosticCode";\n cda -> diagnosticReport.status = 'registered' "stats";\n cda.component as component then {\n component.structuredBody as body then {\n body.component as component then {\n component.section as srcSection then {\n srcSection.code -> composition.section as tgtSection then ClinicalDocumentSection(cda, srcSection, patient, tgtSection, bundle, encounter, diagnosticReport);\n };\n };\n } "body";\n };\n } "diagnostic";\n}\n\ngroup ClinicalDocumentSection(source cda : ClinicalDocument, source src : Section, target patient : Patient, target tgt, target bundle : Bundle, target enc : Encounter, target dReport : DiagnosticReport) {\n src.title as t -> tgt.title = (t.dataString);\n src.code -> tgt.code;\n src -> tgt.entry = create('Reference') as reference, reference.reference = ('https://example/DiagnosticReport/' + %dReport.id) "reference";\n src.entry as entry then {\n src.text as cdaText -> tgt.text as fhirText then {\n cdaText -> fhirText.status = 'generated' "narrativeStatus";\n cdaText as t -> fhirText.div = t "narrativeText";\n } "cdaText";\n entry then DiagnosticReportFunction(src, entry, dReport, bundle, enc, patient) "dreport";\n };\n src where src.entry.exists().not() then DiagnosticReportFunction(src, cda, dReport, bundle, enc, patient) "narrative";\n src.component as component then {\n component.section as sec -> tgt.section as tgtSection then ClinicalDocumentSection(cda, sec, patient, tgtSection, bundle, enc, dReport);\n };\n}\n\ngroup DiagnosticReportFunction(source section : section, source src : entry, target dReport : DiagnosticReport, target bundle : Bundle, target encounter : Encounter, target patient : Patient) {\n src.observation as observation then {\n section where code.code = '29299-5' -> bundle.entry as e1, e1.request = create('BackboneElement') as request, request.method = 'POST', e1.resource = create('Observation') as obs1, obs1.id = uuid() as uuid1, e1.fullUrl = append('https://example/Observation/', uuid1), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle) "QuesitoDiagnostico";\n section where code.code = '11329-0' -> bundle.entry as e2, e2.request = create('BackboneElement') as request, request.method = 'POST', e2.resource = create('Observation') as obs2, obs2.id = uuid() as uuid2, e2.fullUrl = append('https://example/Observation/', uuid2), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs2.id) then {\n section -> obs2.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> obs2.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> obs2.status = 'final' "STatusobse";\n section.code -> obs2.code;\n observation.statusCode as s then {\n s.code as cos -> obs2.status = translate(cos, '#OBSstatus', 'code') "codeS";\n } "status";\n section.component as component then {\n component.section as section then {\n section.code where code = '10160-0' then {\n section.entry as entry then {\n entry.substanceAdministration as subAdmin -> bundle.entry as e11, e11.request = create('BackboneElement') as request, request.method = 'POST', e11.resource = create('MedicationStatement') as medicationstatement, medicationstatement.id = uuid() as uuid11, e11.fullUrl = append('https://example/MedicationStatement/', uuid11), request.url = 'MedicationStatement', obs2.partOf = create('Reference') as reference, reference.reference = ('https://example/MedicationStatement/' + %medicationstatement.id) then MedicationStatement(subAdmin, medicationstatement, patient, encounter, bundle) "creat";\n };\n } "sectionCode";\n section.code where code = '48765-2' then {\n section -> bundle.entry as e4, e4.request = create('BackboneElement') as request, request.method = 'POST', e4.resource = create('List') as list1, list1.id = uuid() as uuid4, e4.fullUrl = append('https://example/List/', uuid4), request.url = 'List', obs2.focus = create('Reference') as reference, reference.reference = ('https://example/List/' + %list1.id) then {\n section -> list1.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> list1.status = 'current' "listatus";\n section -> list1.mode = 'working' "lstmod";\n section -> list1.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> list1.entry as entryList1 then {\n section.entry as entry then {\n entry.act as act1 -> bundle.entry as e5, e5.request = create('BackboneElement') as request, request.method = 'POST', e5.resource = create('AllergyIntolerance') as allergy, allergy.id = uuid() as uuid5, e5.fullUrl = append('https://example/AllergyIntolerance/', uuid5), request.url = 'AllergyIntolerance', entryList1.item = create('Reference') as reference, reference.reference = ('https://example/AllergyIntolerance/' + %allergy.id) then allergyFunction(act1, allergy, patient, encounter) "allergy";\n } "entryAll";\n } "entryList";\n } "section";\n } "conditionAllergie";\n };\n } "subSection";\n section.entry as entry then {\n entry.observation -> bundle.entry as e3, e3.request = create('BackboneElement') as request, request.method = 'POST', e3.resource = create('Condition') as condition, condition.id = uuid() as uuid3, e3.fullUrl = append('https://example/Condition/', uuid3), request.url = 'Condition', obs2.focus = create('Reference') as reference, reference.reference = ('https://example/Condition/' + %condition.id) then ConditionFunction(observation, condition, patient, encounter, bundle) "condition";\n entry.organizer as organizer then {\n section -> bundle.entry as e11, e11.request = create('BackboneElement') as request, request.method = 'POST', e11.resource = create('List') as list11, list11.id = uuid() as uuid11, e11.fullUrl = append('https://example/List/', uuid11), request.url = 'List', obs2.focus = create('Reference') as reference, reference.reference = ('https://example/List/' + %list11.id) then {\n section -> list11.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> list11.status = 'current' "liststat";\n section -> list11.mode = 'working' "listmd";\n section -> list11.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n organizer -> list11.entry as entryList2 then {\n organizer -> bundle.entry as e12, e12.request = create('BackboneElement') as request, request.method = 'POST', e12.resource = create('FamilyMemberHistory') as familyMember, familyMember.id = uuid() as uuid12, e12.fullUrl = append('https://example/FamilyMemberHistory/', uuid12), request.url = 'FamilyMemberHistory', entryList2.item = create('Reference') as reference, reference.reference = ('https://example/FamilyMemberHistory/' + %familyMember.id) then FamilyMemberFunction(organizer, familyMember, patient) "family";\n } "org";\n } "List";\n };\n };\n } "StoriaClinica1";\n section where code.code = '30954-2' -> bundle.entry as e4, e4.request = create('BackboneElement') as request, request.method = 'POST', e4.resource = create('Observation') as obs4, obs4.id = uuid() as uuid4, e4.fullUrl = append('https://example/Observation/', uuid4), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs4.id) then Observation(observation, patient, encounter, obs4, bundle) "PrecedentiEsamiEseguiti";\n section where code.code = '29548-5' -> bundle.entry as e5, e5.request = create('BackboneElement') as request, request.method = 'POST', e5.resource = create('Observation') as obs5, obs5.id = uuid() as uuid5, e5.fullUrl = append('https://example/Observation/', uuid5), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs5.id) then Observation(observation, patient, encounter, obs5, bundle) "Diagnosi";\n } "entryObs";\n src.act as act then {\n section where code.code = '62387-6' -> dReport.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) then {\n act.code -> encounter.type "type";\n act.effectiveTime as effectiveTime -> encounter.period as period then {\n effectiveTime -> period.start = create('dateTime') as start then TSDateTime(effectiveTime, start) "val";\n } "period";\n act -> bundle.entry as e10, e10.request = create('BackboneElement') as request, request.method = 'POST', e10.resource = create('Procedure') as procedureRes, procedureRes.id = uuid() as uuid10, e10.fullUrl = append('https://example/Procedure/', uuid10), request.url = 'Procedure', encounter.reasonReference = create('Reference') as reference, reference.reference = ('https://example/Procedure/' + %procedureRes.id) then {\n act -> procedureRes.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n act -> procedureRes.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n act.statusCode -> procedureRes.status "status1";\n act where statusCode.exists().not() -> procedureRes.status = 'unknown' "status2";\n act.entryRelationship as entryRel then {\n entryRel.procedure as proc -> bundle.entry as e9, e9.request = create('BackboneElement') as request, request.method = 'POST', e9.resource = create('Procedure') as procedure2, procedure2.id = uuid() as uuid9, e9.fullUrl = append('https://example/Procedure/', uuid9), request.url = 'Procedure', procedureRes.partOf = create('Reference') as reference, reference.reference = ('https://example/Procedure/' + %procedure2.id) then Procedure(proc, patient, encounter, procedure2, bundle) "procedurePrestazioni";\n entryRel.substanceAdministration as subAdmin -> bundle.entry as e8, e8.request = create('BackboneElement') as request, request.method = 'POST', e8.resource = create('MedicationAdministration') as medAdmin, medAdmin.id = uuid() as uuid8, e8.fullUrl = append('https://example/MedicationAdministration/', uuid8), request.url = 'MedicationAdministration', procedureRes.partOf = create('Reference') as reference, reference.reference = ('https://example/MedicationAdministration/' + %medAdmin.id) then MedicationAdministration(subAdmin, patient, encounter, medAdmin, bundle) "farmacPrestazioni";\n entryRel.observation as entryRobs -> bundle.entry as e7, e7.request = create('BackboneElement') as request, request.method = 'POST', e7.resource = create('Observation') as obs7, obs7.id = uuid() as uuid7, e7.fullUrl = append('https://example/Observation/', uuid7), request.url = 'Observation', procedureRes.partOf = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs7.id) then ObservationPrest(entryRobs, patient, encounter, obs7, bundle) "osservazioniPrestazioni";\n entryRel.act as act2 -> bundle.entry as e6, e6.request = create('BackboneElement') as request, request.method = 'POST', e6.resource = create('Procedure') as procedure3, procedure3.id = uuid() as uuid6, e6.fullUrl = append('https://example/Procedure/', uuid6), request.url = 'Procedure', procedureRes.partOf = create('Reference') as reference, reference.reference = ('https://example/Procedure/' + %procedure3.id) then Procedure(act2, patient, encounter, procedure3, bundle) "procedureGenerichePrestazioni";\n } "Relationship";\n } "proceduraMadre";\n } "Prestazioni";\n section where code.code = '80615-8' -> bundle.entry as e12, e12.request = create('BackboneElement') as request, request.method = 'POST', e12.resource = create('Observation') as obs12, obs12.id = uuid() as uuid12, e12.fullUrl = append('https://example/Observation/', uuid12), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs12.id) then Observation(act, patient, encounter, obs12, bundle) "Followup";\n } "entryAct";\n // src.substanceAdministration\n src.substanceAdministration as substanceadmin then {\n section where code.code = '93341-6' -> bundle.entry as e6, e6.request = create('BackboneElement') as request, request.method = 'POST', e6.resource = create('MedicationRequest') as medre1, medre1.id = uuid() as uuid6, e6.fullUrl = append('https://example/MedicationRequest/', uuid6), request.url = 'MedicationRequest', dReport.basedOn = create('Reference') as reference, reference.reference = ('https://example/MedicationRequest/' + %medre1.id) then MedicationRequest(substanceadmin, patient, encounter, medre1, bundle) "TerapiaFarmacologicaConsigliata";\n } "substanceadmin";\n section where section.entry.exists().not() then {\n section where (code.code = '48765-2') -> bundle.entry as e2, e2.request = create('BackboneElement') as request, request.method = 'POST', e2.resource = create('Observation') as obs1, obs1.id = uuid() as uuid2, e2.fullUrl = append('https://example/Observation/', uuid2), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs1.id) then {\n section -> obs1.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> obs1.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> obs1.status = 'final' "STatusobse";\n section.code -> obs1.code;\n section.statusCode as s then {\n s.code as cos -> obs1.status = translate(cos, '#OBSstatus', 'code') "codeS";\n } "status";\n section.text as text -> bundle.entry as e5, e5.request = create('BackboneElement') as request, request.method = 'POST', e5.resource = create('AllergyIntolerance') as allergy, allergy.id = uuid() as uuid5, e5.fullUrl = append('https://example/AllergyIntolerance/', uuid5), request.url = 'AllergyIntolerance', obs1.focus = create('Reference') as reference, reference.reference = ('https://example/AllergyIntolerance/' + %allergy.id) then {\n section -> allergy.patient = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> allergy.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> allergy.clinicalStatus as clinicalStatus then {\n section -> clinicalStatus.coding = create('Coding') as coding then {\n section -> coding.code = 'active' "code";\n section -> coding.system = 'http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical' "system";\n } "coding";\n } "status";\n text -> allergy.note as note then {\n text as t -> note.text = create('string') as textNote then EDstring(t, textNote) "note";\n } "narrative";\n } "allergytext";\n } "allergyAct";\n section where (code.code = '93341-6') then {\n section.text as text -> bundle.entry as e13, e13.request = create('BackboneElement') as request, request.method = 'POST', e13.resource = create('MedicationRequest') as obs13, obs13.id = uuid() as uuid13, e13.fullUrl = append('https://example/MedicationRequest/', uuid13), request.url = 'MedicationRequest', dReport.basedOn = create('Reference') as reference, reference.reference = ('https://example/MedicationRequest/' + %obs13.id) then {\n section -> obs13.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> obs13.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> obs13.intent = 'order' "intent";\n section where statusCode.exists().not() -> obs13.status = 'unknown' "st";\n text -> obs13.note as note then {\n text as t -> note.text = create('string') as textNote then EDstring(t, textNote) "note";\n } "note";\n section -> obs13.medication = create('CodeableConcept') as code then {\n section -> code.text = 'string' "string";\n } "code";\n } "txtsec";\n } "MedicationRequest";\n section where (code.code = '55110-1').not() and (code.code = '93341-6').not() and (code.code = '48765-2').not() then {\n section.text as text -> bundle.entry as e13, e13.request = create('BackboneElement') as request, request.method = 'POST', e13.resource = create('Observation') as obs13, obs13.id = uuid() as uuid13, e13.fullUrl = append('https://example/Observation/', uuid13), request.url = 'Observation', dReport.result = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs13.id) then {\n section -> obs13.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n section -> obs13.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n section -> obs13.status = 'preliminary' "obsst";\n section.code -> obs13.code "obscde";\n section -> obs13.status = 'final' "statusS";\n text -> obs13.note as note then {\n text as t -> note.text = create('string') as textNote then EDstring(t, textNote) "note";\n } "narrative";\n } "txtsec";\n } "NonConclusion";\n section where (code.code = '55110-1') then {\n section.text as t -> dReport.conclusion = create('string') as textConclusion then EDstring(t, textConclusion) "conc";\n } "conclusion";\n } "whereCond";\n}\n\ngroup Observation(source cda : observation, target patient : Patient, target encounter : Encounter, target ob : Observation, target bundle : Bundle) {\n cda -> ob.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n cda -> ob.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n cda.code -> ob.code;\n cda -> ob.status = 'final' "Stats";\n // value datatype\n cda.value : INT as int -> ob.value = (int.value);\n cda.value : ST as st -> ob.value = create('string'), ob.value = (st.dataString);\n cda.value : BL as boolean -> ob.value = (boolean.value) "boolean";\n cda.value : CE as val then {\n val -> ob.value = create('CodeableConcept') as ce then {\n val.originalText as originalText then {\n originalText.reference as reference -> ce.text = (reference.value);\n };\n val -> ce.coding as coding then {\n val.code as code -> coding.code = cast(code, 'string');\n val.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n val.displayName as display -> coding.display = cast(display, 'string');\n } "code";\n val.translation as translation -> ce.coding as coding then {\n translation.code as code -> coding.code = cast(code, 'string');\n translation.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n translation.displayName as display -> coding.display = cast(display, 'string');\n translation.qualifier as qualifier then {\n qualifier.value as value -> ce.coding as coding then {\n value.code as code -> coding.code = cast(code, 'string');\n value.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n value.displayName as display -> coding.display = cast(display, 'string');\n };\n };\n };\n } "coding";\n } "val";\n cda.value : CD as val then {\n val -> ob.value = create('CodeableConcept') as ce then {\n val.originalText as originalText then {\n originalText.reference as reference -> ce.text = (reference.value);\n };\n val -> ce.coding as coding then {\n val.code as code -> coding.code = cast(code, 'string');\n val.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n val.displayName as display -> coding.display = cast(display, 'string');\n } "code";\n val.translation as translation -> ce.coding as coding then {\n translation.code as code -> coding.code = cast(code, 'string');\n translation.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n translation.displayName as display -> coding.display = cast(display, 'string');\n translation.qualifier as qualifier then {\n qualifier.value as value -> ce.coding as coding then {\n value.code as code -> coding.code = cast(code, 'string');\n value.codeSystem as system -> coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n value.displayName as display -> coding.display = cast(display, 'string');\n };\n };\n };\n } "coding";\n } "val";\n cda.value : PQ as val then {\n val -> ob.value = create('Quantity') as quantity then {\n val.value as value -> quantity.value = value;\n val.unit as unit -> quantity.unit = unit;\n } "quantity";\n } "valueQuantity";\n cda.effectiveTime as effectiveTime where (value.exists()) -> ob.effective = create('dateTime') as value then TSDateTime(effectiveTime, value) "value1";\n cda.effectiveTime as effectiveTime where (low.exists()) -> ob.effective = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n cda.text as text -> ob.note as note then {\n text.reference as reference -> note.text = (reference.value) "text";\n } "note";\n cda.statusCode as s then {\n s.code as cos -> ob.status = translate(cos, '#OBSstatus', 'code') "codeS";\n } "status";\n}\n\ngroup ConditionFunction(source src : cdaElement, target tgt : Condition, target patient : patient, target encounter : encounter, target bundle : Bundle) {\n src.code -> tgt.category;\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src.statusCode as stscode -> tgt.verificationStatus as verifstatus then {\n stscode as codeS -> verifstatus.coding = create('Coding') as coding then {\n codeS.code -> coding.code = 'confirmed';\n codeS -> coding.system = 'http://terminology.hl7.org/CodeSystem/condition-ver-status' "system";\n codeS -> coding.display = cast('Confirmed', 'string') "display";\n } "coding";\n } "verifstatus";\n src.effectiveTime as effectiveTime -> tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n src.value -> tgt.code;\n src.entryRelationship as entryRelationship then {\n entryRelationship.observation as obsentry then {\n obsentry.code where code = '89261-2' then {\n obsentry -> tgt.evidence as evidence, bundle.entry as e1, e1.request = create('BackboneElement') as request, request.method = 'POST', e1.resource = create('Observation') as obsy, obsy.id = uuid() as uuid1, e1.fullUrl = append('https://example/Observation/', uuid1), request.url = 'Observation', evidence.detail = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obsy.id) then Observation(obsentry, patient, encounter, obsy, bundle) "observation";\n } "observation";\n obsentry.code where code = '33999-4' then {\n obsentry.value as value -> tgt.clinicalStatus as clinicalstatus then {\n value as val -> clinicalstatus.coding = create('Coding') as coding then {\n val where (code = 'LA9041-0') -> coding.code = 'resolved' "code";\n val where (code = 'LA18632-2') -> coding.code = 'inactive' "code";\n val where (code = 'LA16666-2') -> coding.code = 'active' "code";\n val -> coding.system = 'http://terminology.hl7.org/CodeSystem/condition-clinical' "system";\n val.displayName as display -> coding.display = cast(display, 'string') "display";\n } "coding";\n obsentry.text as text then {\n text.reference as reference -> clinicalstatus.text = (reference.value) "text";\n };\n } "clinicalstatus";\n } "clinicalStatus2";\n } "EntryRelObsevation";\n } "entryR";\n}\n\ngroup Procedure(source src : procedure, target patient : Patient, target encounter : Encounter, target tgt : Procedure, target bundle : Bundle) {\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src.statusCode -> tgt.status "status1";\n src where statusCode.exists().not() -> tgt.status = 'unknown' "status2";\n src.id -> tgt.identifier;\n src.code -> tgt.code;\n src.effectiveTime as effectiveTime where (value.exists()) -> tgt.performed = create('dateTime') as value then TSDateTime(effectiveTime, value) "value1";\n src.effectiveTime as effectiveTime where (low.exists()) -> tgt.performed = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n src.methodCode as methodCode -> tgt.extension as ext1 then ITMethodExt(methodCode, ext1);\n src.participant as participant then {\n participant.participantRole as participantRole -> tgt.performer as performer then {\n participantRole.playingDevice as device -> bundle.entry as e2, e2.request = create('BackboneElement') as request, request.method = 'POST', e2.resource = create('Device') as deviceRes, deviceRes.id = uuid() as uuid2, e2.fullUrl = append('https://example/Device/', uuid2), request.url = 'Device', performer.actor = create('Reference') as reference, reference.reference = ('https://example/Device/' + %deviceRes.id) then {\n device.manufacturerModelName as manufacturerModelName then {\n manufacturerModelName.displayName as displayName -> deviceRes.manufacturer = cast(displayName, 'string') "manuf";\n } "manufacturer";\n device.code -> deviceRes.type;\n } "device";\n };\n };\n src.entryRelationship as entryR then {\n entryR.observation as observation -> bundle.entry as e3, e3.request = create('BackboneElement') as request, request.method = 'POST', e3.resource = create('Observation') as obs1, obs1.id = uuid() as uuid3, e3.fullUrl = append('https://example/Observation/', uuid3), request.url = 'Observation', tgt.partOf = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle) "Parametri";\n entryR.act as act then {\n act.text as text -> tgt.note as note then {\n text.reference as reference -> note.text = (reference.value) "text";\n } "note";\n };\n } "entryRelProcedure";\n}\n\ngroup ITMethodExt(source src, target ext) {\n src -> ext.url = 'http://hl7.org/fhir/StructureDefinition/procedure-method' "url";\n src -> ext.value = create('CodeableConcept') as value then CECodeableConcept(src, value) "value";\n}\n\ngroup MedicationAdministration(source src : substanceAdministration, target patient : Patient, target encounter : Encounter, target tgt : MedicationAdministration, target bundle : Bundle) {\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.context = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src.statusCode -> tgt.status "status1";\n src where statusCode.exists().not() -> tgt.status = 'unknown' "status2";\n src.id -> tgt.identifier;\n src.effectiveTime as effectiveTime where (value.exists()) -> tgt.effective = create('dateTime') as value then TSDateTime(effectiveTime, value) "value1";\n src.effectiveTime as effectiveTime where (low.exists()) -> tgt.effective = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n src -> tgt.dosage as dosage then {\n src.routeCode -> dosage.route "route";\n src.repeatNumber as repeatNumber -> dosage.rate = create('SimpleQuantity') as value then PQQuantity(repeatNumber, value) "repQ";\n src.approachSiteCode -> dosage.site "site";\n src.targetSiteCode -> dosage.site "site";\n } "dosage";\n src.consumable as consumable -> bundle.entry as e1, e1.request = create('BackboneElement') as request, request.method = 'POST', e1.resource = create('Medication') as medication, medication.id = uuid() as uuid1, e1.fullUrl = append('https://example/Medication/', uuid1), request.url = 'Medication', tgt.medication = create('Reference') as medref, medref.reference = ('https://example/Medication/' + %medication.id) then Medication(src, medication, patient, bundle) "medication";\n src.participant as participant then {\n participant.participantRole as participantRole -> tgt.performer as performer then {\n participantRole.device as device -> bundle.entry as e2, e2.request = create('BackboneElement') as request, request.method = 'POST', e2.resource = create('Device') as deviceRes, deviceRes.id = uuid() as uuid2, e2.fullUrl = append('https://example/Device/', uuid2), request.url = 'Device', performer.actor = create('Reference') as reference, reference.reference = ('https://example/Device/' + %deviceRes.id) then {\n device.ManufacturerModelName as ManufacturerModelName then {\n ManufacturerModelName.code -> deviceRes.manufacturer "manuf";\n } "manufacturer";\n };\n };\n };\n src.entryRelationship as entryR then {\n entryR.observation as observation -> bundle.entry as e3, e3.request = create('BackboneElement') as request, request.method = 'POST', e3.resource = create('Observation') as obs1, obs1.id = uuid() as uuid3, e3.fullUrl = append('https://example/Observation/', uuid3), request.url = 'Observation', tgt.partOf = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle) "Parametri";\n entryR.act as act then {\n act.text as text -> tgt.note as note then {\n text.reference as reference -> note.text = (reference.value) "text";\n } "note";\n };\n } "entryRelMedication";\n src where (src.doseQuantity.exists() or src.rateQuantity.exists()) -> bundle.entry as e1, e1.request = create('BackboneElement') as request, request.method = 'POST', e1.resource = create('MedicationRequest') as medicationRq, medicationRq.id = uuid() as uuid1, e1.fullUrl = append('https://example/MedicationRequest/', uuid1), request.url = 'MedicationRequest', tgt.request = create('Reference') as reference, reference.reference = ('https://example/MedicationRequest/' + %medicationRq.id) then MedicationRequest(src, patient, encounter, medicationRq, bundle) "medRequ";\n src.text as text -> tgt.note as note then {\n text -> note.text "text";\n } "note";\n}\n\ngroup ObservationPrest(source src : observation, target patient : Patient, target encounter : Encounter, target tgt : Observation, target bundle : Bundle) {\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src.statusCode as s then {\n s.code as cos -> tgt.status = translate(cos, '#OBSstatus', 'code') "codeS";\n } "status";\n src.id -> tgt.identifier;\n src.code -> tgt.code;\n src.effectiveTime as effectiveTime where (value.exists()) -> tgt.perfomed = create('dateTime') as value then TSDateTime(effectiveTime, value) "value1";\n src.effectiveTime as effectiveTime where (low.exists()) -> tgt.perfomed = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n src.methodCode -> tgt.method;\n src.participant as participant then {\n participant.participantRole as participantRole then {\n participantRole.device as device -> bundle.entry as e2, e2.request = create('BackboneElement') as request, request.method = 'POST', e2.resource = create('Device') as deviceRes, deviceRes.id = uuid() as uuid2, e2.fullUrl = append('https://example/Device/', uuid2), request.url = 'Device', tgt.device = create('Reference') as reference, reference.reference = ('https://example/Device/' + %deviceRes.id) then {\n device.ManufacturerModelName as ManufacturerModelName then {\n ManufacturerModelName.code -> deviceRes.manufacturer "manuf";\n } "manufacturer";\n };\n };\n };\n src.entryRelationship as entryR then {\n entryR.observation as observation -> bundle.entry as e3, e3.request = create('BackboneElement') as request, request.method = 'POST', e3.resource = create('Observation') as obs1, obs1.id = uuid() as uuid3, e3.fullUrl = append('https://example/Observation/', uuid3), request.url = 'Observation', tgt.hasMember = create('Reference') as reference, reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle) "Parametri";\n entryR.act as act then {\n act.text as text -> tgt.note as note then {\n text.reference as reference -> note.text = (reference.value) "text";\n } "note";\n };\n } "entryRelOsservazioni";\n}\n\ngroup MedicationRequest(source src : substanceAdministration, target patient : Patient, target encounter : Encounter, target tgt : MedicationRequest, target bundle : Bundle) {\n // default + mandatory\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src -> tgt.intent = 'order' "intent";\n src where statusCode.exists().not() -> tgt.status = 'unknown' "st";\n src.statusCode as sc then {\n sc.code as cos -> tgt.status = translate(cos, '#MedicationStatusMap', 'code') "codeS";\n } "status";\n src.text as txt -> tgt.note as note then {\n txt.reference as reference -> note.text = (reference.value) "text";\n } "note";\n src.effectiveTime : IVL_TS as eff -> tgt.dosageInstruction = create('Dosage') as dosage then {\n eff -> dosage.timing = create('Timing') as timing then {\n eff -> timing.repeat as rep then {\n eff as eff where (value.exists()) -> rep.bounds = create('dateTime') as value then TSDateTime(eff, value) "value1";\n eff as eff where (low.exists()) -> rep.bounds = create('Period') as value then IVLTSPeriod(eff, value) "valuePeriod";\n } "rep";\n } "timing";\n } "period";\n src.effectiveTime : EIVL_TS as effe -> tgt.dosageInstruction = create('Dosage') as dosage then {\n effe -> dosage.timing = create('Timing') as timing then {\n effe -> timing.repeat as rep then {\n effe.eventCode as ev -> rep.when = (ev.code);\n } "rep";\n } "timing";\n } "period";\n src.effectiveTime : IVL_TS as eff -> tgt.dosageInstruction = create('Dosage') as dosage, dosage.timing = create('Timing') as timing, timing.event = (eff.value) "tim";\n src.effectiveTime : PIVL_TS as eff -> tgt.dosageInstruction = create('Dosage') as dosage then {\n eff -> dosage.timing = create('Timing') as timing then periodTiming(eff, timing) "cod";\n } "eff";\n src where (src.doseQuantity.exists() or src.rateQuantity.exists()) then {\n src -> tgt.dosageInstruction = create('Dosage') as dosageInstruction then {\n src.doseQuantity as doseQuant then {\n doseQuant.originalText as ot then {\n ot.reference -> dosageInstruction.text;\n } "ot";\n doseQuant -> dosageInstruction.doseAndRate as dosageRate then {\n doseQuant -> dosageRate.dose = create('Range') as d then {\n doseQuant -> d.low = create('SimpleQuantity') as l then {\n doseQuant.low as lo -> l.value = (lo.value);\n doseQuant.low as lo -> l.unit = (lo.unit);\n } "low";\n doseQuant -> d.high = create('SimpleQuantity') as h then {\n doseQuant.high as hi -> h.value = (hi.value);\n doseQuant.high as hi -> h.unit = (hi.unit);\n } "low";\n } "d";\n } "dosageRate";\n };\n src.rateQuantity as rateQuantity then {\n rateQuantity.originalText as ot then {\n ot.reference -> dosageInstruction.text;\n } "ot";\n rateQuantity -> dosageInstruction.doseAndRate as dosageRate then {\n rateQuantity -> dosageRate.rate = create('Range') as d then {\n rateQuantity -> d.low = create('SimpleQuantity') as l then {\n rateQuantity.low as lo -> l.value = (lo.value);\n rateQuantity.low as lo -> l.unit = (lo.unit);\n } "low";\n rateQuantity -> d.high = create('SimpleQuantity') as h then {\n rateQuantity.high as hi -> h.value = (hi.value);\n rateQuantity.high as hi -> h.unit = (hi.unit);\n } "high";\n } "r";\n } "dosageRate";\n } "rate";\n src.routeCode -> dosageInstruction.route "route";\n src.approachSiteCode -> dosageInstruction.site "site";\n src.targetSiteCode -> dosageInstruction.site "site";\n } "dosageIn";\n } "condition";\n src.consumable as consumable -> bundle.entry as e1, e1.request = create('BackboneElement') as request, request.method = 'POST', e1.resource = create('Medication') as medication, medication.id = uuid() as uuid1, e1.fullUrl = append('https://example/Medication/', uuid1), request.url = 'Medication', tgt.medication = create('Reference') as medref, medref.reference = ('https://example/Medication/' + %medication.id) then Medication(src, medication, patient, bundle) "medication";\n src.entryRelationship as entryRelationship then {\n entryRelationship.supply as supply -> tgt.dispenseRequest as dispenseRequest then {\n supply.quantity as quantityCDA -> dispenseRequest.quantity as quantityFHIR then {\n quantityCDA -> quantityFHIR.value = (quantityCDA.value) "value";\n };\n };\n } "entryR";\n src.participant as participant then {\n participant then Practitioner(participant, tgt, bundle) "function";\n participant.effectiveTime -> tgt.authoredOn "autor";\n } "Partecipant";\n}\n\ngroup periodTiming(source effectiveTime : PIVL_TS, target timing : Timing) {\n effectiveTime -> timing.repeat as r then {\n effectiveTime.period as p -> r.period = (p.value);\n effectiveTime.period as p -> r.periodUnit = (p.unit);\n } "repeat";\n}\n\ngroup Medication(source src : cda, target tgt : Medication, target patient : Patient, target bundle : Bundle) {\n src.consumable as consumable then {\n consumable.manufacturedProduct as manufacturedProduct then {\n manufacturedProduct.manufacturedMaterial as manufacturedMaterial then {\n manufacturedMaterial.code -> tgt.code "CE";\n src.administrationUnitCode -> tgt.form "form";\n } "material";\n } "product";\n };\n src.entryRelationship as entryR then {\n entryR.observation as observation then {\n observation.code where displayName = 'Grammatura' -> tgt.ingredient as ingredient then {\n src.consumable as consumable then {\n consumable.manufacturedProduct as manufacturedProduct then {\n manufacturedProduct.manufacturedMaterial as manufacturedMaterial then {\n manufacturedMaterial.code as code -> ingredient.item = create('CodeableConcept') as value then CECodeableConcept(code, value) "CE";\n } "material";\n } "product";\n };\n observation.value as value -> ingredient.strength as strength then {\n value -> strength.numerator as numerator then {\n value -> numerator.value = (value.value) "valueN";\n } "numerator";\n value -> strength.denominator as denominator then {\n value -> denominator.value = 1 "valueD";\n } "denominator";\n } "strenght";\n } "ingredient";\n observation.code where displayName = 'Quantità nella Confezione' then {\n observation.value as value -> tgt.amount as amount then {\n value -> amount.numerator as numerator then {\n value -> numerator.value = (value.value) "valueN";\n } "numerator";\n value -> amount.denominator as denominator then {\n value -> denominator.value = 1 "valueD";\n } "denominator";\n } "amount";\n } "quantita";\n } "obs";\n } "entryR";\n}\n\ngroup MedicationStatement(source src : subAdmin, target tgt : MedicationStatement, target patient : Patient, target encounter : Encounter, target bundle : Bundle) {\n src -> tgt.subject = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src.statusCode -> tgt.status;\n src where statusCode.exists().not() -> tgt.status = 'unknown' "notpresent";\n src.consumable as consumable then {\n consumable.manufacturedProduct as manufacturedProduct then {\n manufacturedProduct.manufacturedMaterial as manufacturedMaterial then {\n manufacturedMaterial.code as code -> tgt.medication = create('CodeableConcept') as ce then CECodeableConcept(code, ce) "CE";\n } "material";\n } "product";\n };\n}\n\ngroup FamilyMemberFunction(source src : organizer, target tgt : FamilyMemberHistory, target patient : patient) {\n src -> tgt.patient = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "patReference";\n src.statusCode -> tgt.status;\n src.effectiveTime as effectiveTime -> tgt.date = create('date') as value then TSDateTime(effectiveTime, value) "date";\n src.subject as subject then {\n subject.relatedSubject as relatedSubject then {\n relatedSubject.code -> tgt.relationship "relationshipCode";\n relatedSubject.subject as subject -> tgt.sex as sex then {\n subject.administrativeGenderCode as administrativeGenderCode -> sex.coding as coding then {\n administrativeGenderCode.code as sexCode -> coding.code = translate(sexCode, '#cm-v3-administrative-gender', 'code') "gender";\n administrativeGenderCode -> coding.system = 'http://hl7.org/fhir/administrative-gender' "system";\n } "coding";\n };\n } "relatedSub";\n } "relationship";\n src.component as component -> tgt.condition as condition then {\n component.observation as observation then {\n observation.code -> condition.code;\n observation.text as text -> tgt.note as note then {\n text.reference as reference -> note.text = (reference.value) "value";\n } "reference";\n observation.statusCode -> tgt.status;\n // observation.effectiveTime as effectiveTime -> condition.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n observation where observation.effectiveTime.exists() then {\n observation.effectiveTime as effectiveTime -> tgt.condition = create('BackboneElement') as condition then {\n observation.code -> condition.code;\n observation.value -> condition.outcome "codeable";\n effectiveTime -> condition.onset = create('Period') as period then {\n effectiveTime -> period.start = create('dateTime') as start then TSDateTime(effectiveTime, start) "val";\n } "efft";\n } "effttemp";\n } "cont";\n observation.value -> condition.outcome "codeable";\n observation.entryRelationship as entryR then {\n entryR.observation as obs then {\n obs where (code.code = '35267-4') then {\n obs.value as value -> condition.onset = create('Age') as Age then {\n value.value as valueAge -> Age.value = valueAge "age";\n value.unit as unit -> Age.code = unit;\n value.unit as unit -> Age.unit = unit;\n value -> Age.system = 'http://unitsofmeasure.org' "system";\n };\n } "insorgenza";\n obs where (code.code = '39016-1') then {\n obs.value as value -> tgt.deceased = create('Age') as Age then {\n value.value as valueAge -> Age.value = valueAge "age";\n value.unit as unit -> Age.code = unit;\n value.unit as unit -> Age.unit = unit;\n value -> Age.system = 'http://unitsofmeasure.org' "system";\n };\n } "death";\n } "obser";\n } "EntryRel";\n };\n };\n}\n\ngroup allergyFunction(source src : cdaElement, target tgt : AllergyIntolerance, target patient : patient, target encounter : encounter) {\n src -> tgt.patient = create('Reference') as reference, reference.reference = ('https://example/Patient/' + %patient.id) "reference";\n src -> tgt.encounter = create('Reference') as reference, reference.reference = ('https://example/Encounter/' + %encounter.id) "reference";\n src.entryRelationship as entryRelationship1 then {\n entryRelationship1.observation as observation1 then {\n observation1.effectiveTime as effectiveTime -> tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) "valuePeriod";\n observation1.value as code then {\n code.code as code1 -> tgt.type = translate(code1, '#AllergyTypeMap', 'code') "type";\n code.code as code1 -> tgt.category = translate(code1, '#AllergyCategoryMap', 'code') "category";\n } "code";\n observation1.participant as participant -> tgt.reaction as reaction then {\n observation1.entryRelationship as entryRelationship2 where (typeCode = 'MFST') then {\n entryRelationship2.observation as observation2 then {\n observation2.value -> reaction.manifestation "manifestation";\n observation2.effectiveTime as effectiveTime then {\n effectiveTime.low as low -> reaction.onset = create('dateTime') as value then TSDateTime(low, value) "valuePeriodLow";\n } "low";\n } "observ2";\n } "entryR2";\n participant.participantRole as participantRole then {\n participantRole.playingEntity as playingEntity then {\n playingEntity.code -> reaction.substance "reaction";\n };\n };\n };\n observation1.entryRelationship as entryRelationship2 where (typeCode = 'MFST') then {\n entryRelationship2.observation as observation2 where observation1.participant.exists().not() -> tgt.reaction as reaction then {\n observation2.value -> reaction.manifestation "manifestation";\n observation2.effectiveTime as effectiveTime then {\n effectiveTime.low as low -> reaction.onset = create('dateTime') as value then TSDateTime(low, value) "valuePeriodLow";\n } "low";\n } "observ2";\n } "entryR2";\n observation1.entryRelationship as entryRelationship3 where (typeCode = 'SUBJ') then {\n entryRelationship3.observation as observation3 then {\n observation3.value as value then {\n value.code as c -> tgt.criticality = translate(c, '#CricalityMap', 'code') "value";\n } "criticality";\n } "observ3";\n entryRelationship3.act as act -> tgt.note as note then {\n act.text as text then {\n text.reference as reference -> note.text = (reference.value);\n } "note";\n };\n } "entryR3";\n observation1.entryRelationship as entryRelationship4 where (typeCode = 'REFR') then {\n entryRelationship4.observation as observation4 then {\n observation4.value as value -> tgt.clinicalStatus as clinicalStatus then {\n value as valu -> clinicalStatus.coding = create('Coding') as coding then {\n valu where (code = 'LA9041-0') -> coding.code = 'resolved' "code";\n valu where (code = 'LA18632-2') -> coding.code = 'inactive' "code";\n valu where (code = 'LA16666-2') -> coding.code = 'active' "code";\n valu -> coding.system = 'http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical' "system";\n valu.displayName as display -> coding.display = cast(display, 'string') "display";\n } "coding";\n } "clinicalStatus";\n } "observ4";\n } "entryR4";\n };\n } "entryrelationship";\n}\n\ngroup Practitioner(source src : participant, target tgt : MedicationRequest, target bundle : Bundle) {\n src -> bundle.entry as e22, e22.request = create('BackboneElement') as request, request.method = 'PUT', e22.resource = create('Practitioner') as practitioner1 then {\n src.participantRole as practr then {\n practr.id as id -> practitioner1.identifier as identifier then {\n id.root as r -> identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') "root1";\n id.extension as ext -> identifier.value = ext "ext";\n id.assigningAuthorityName as s -> identifier.assigner as a, a.display = s;\n id.root as r then {\n id.extension as ext -> practitioner1.id = (r + '-' + ext) as uuid22, e22.fullUrl = append('https://example/Practitioner/', uuid22), tgt.requester = create('Reference') as reference, reference.reference = ('https://example/Practitioner/' + %practitioner1.id) "id";\n } "r";\n } "identifier";\n practr.id as id where (root = '2.16.840.1.113883.2.9.4.3.2') then {\n id.extension as ext -> request.url = append('Practitioner?identifier=', ext) "UUID";\n } "2";\n practr.id as id where (root != '2.16.840.1.113883.2.9.4.3.2') then {\n id.extension as ext -> request.url = append('Practitioner?identifier=', ext) "UUID";\n } "diverso";\n practr -> practitioner1.meta as meta then {\n practr -> meta.tag = create('Coding') as coding then {\n practr -> coding.system = 'http://algoritmodiscoring' "system";\n practr -> coding.code = 'ClinicalDocument/body/TerapiaFarmacologicaConsigliata/participant' "code";\n } "coding";\n } "meta";\n practr.addr -> practitioner1.address;\n practr.telecom -> practitioner1.telecom;\n practr.playingEntity as plentity then {\n plentity.name -> practitioner1.name;\n plentity.birthTime as birthTime then {\n birthTime.value as date -> practitioner1.birthDate = truncate(date, 10);\n } "birth";\n } "partname";\n } "resurceCreation";\n } "practitionerCreate";\n}\n\n</pre>\n </div>" ] ; # fhir:url [ fhir:v "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirAmbReport"^^xsd:anyURI] ; # fhir:version [ fhir:v "0.1.0"] ; # fhir:name [ fhir:v "cda2fhirAmbReport"] ; # fhir:status [ fhir:v "draft"] ; # fhir:date [ fhir:v "2024-09-15T08:16:12+00:00"^^xsd:dateTime] ; # fhir:publisher [ fhir:v "HL7 Italy"] ; # fhir:contact ( [ fhir:name [ fhir:v "HL7 Italy" ] ; ( fhir:telecom [ fhir:system [ fhir:v "url" ] ; fhir:value [ fhir:v "http://hl7.it" ] ] ) ] ) ; # fhir:jurisdiction ( [ ( fhir:coding [ fhir:system [ fhir:v "urn:iso:std:iso:3166"^^xsd:anyURI ] ; fhir:code [ fhir:v "IT" ] ; fhir:display [ fhir:v "Italy" ] ] ) ] ) ; # fhir:structure ( [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument> ] ; fhir:mode [ fhir:v "source" ] ; fhir:alias [ fhir:v "ClinicalDocument" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/AssignedAuthor"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssignedAuthor> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "AssignedAuthor" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/AssignedEntity"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssignedEntity> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "AssignedEntity" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/AssociatedEntity"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssociatedEntity> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "AssociatedEntity" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/CustodianOrganization"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/CustodianOrganization> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "CustodianOrganization" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/OrganizationPartOf"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/OrganizationPartOf> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "OrganizationPartOf" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/Organization"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Organization> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "rapresentedOrganization" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/Section"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Section> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "Section" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/PatientRole"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/PatientRole> ] ; fhir:mode [ fhir:v "queried" ] ; fhir:alias [ fhir:v "PatientRole" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/AD"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AD> ] ; fhir:mode [ fhir:v "source" ] ; fhir:alias [ fhir:v "AD" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Bundle"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Bundle> ] ; fhir:mode [ fhir:v "target" ] ; fhir:alias [ fhir:v "Bundle" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Composition"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Composition> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Composition" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Patient"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Patient> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Patient" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Encounter"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Encounter> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Encounter" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Person"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Person> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Patient" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/List"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/List> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "List" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Practitioner"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Practitioner> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Practitioner" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/Organization"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/Organization> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Organization" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/Act"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Act> ] ; fhir:mode [ fhir:v "produced" ] ; fhir:alias [ fhir:v "Act" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/IVL-PQ"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/IVL-PQ> ] ; fhir:mode [ fhir:v "source" ] ; fhir:alias [ fhir:v "IVL_PQ" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/cda/StructureDefinition/PQ"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/cda/StructureDefinition/PQ> ] ; fhir:mode [ fhir:v "source" ] ; fhir:alias [ fhir:v "PQ" ] ] [ fhir:url [ fhir:v "http://hl7.org/fhir/StructureDefinition/SimpleQuantity"^^xsd:anyURI ; fhir:link <http://hl7.org/fhir/StructureDefinition/SimpleQuantity> ] ; fhir:mode [ fhir:v "target" ] ; fhir:alias [ fhir:v "SimpleQuantity" ] ] ) ; # fhir:import ( [ fhir:v "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirDataTypes"^^xsd:anyURI ; fhir:link <http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirDataTypes> ] [ fhir:v "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirHeader"^^xsd:anyURI ; fhir:link <http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirHeader> ] ) ; # fhir:group ( [ fhir:name [ fhir:v "CdaToBundle" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "cda" ] ; fhir:type [ fhir:v "ClinicalDocument" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "ClinicalDocumentToBody" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e" ] ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "composition" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Composition" ] ] ) ] [ fhir:context [ fhir:v "composition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Composition/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Composition" ] ] ) ] [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "requestPAT" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "requestPAT" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "PUT" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "patient" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Patient" ] ] ) ] [ fhir:context [ fhir:v "patient" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Patient/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e3" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "encounter" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Encounter" ] ] ) ] [ fhir:context [ fhir:v "encounter" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid3" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Encounter/" ] ] [ fhir:value [ fhir:v "uuid3" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Encounter" ] ] ) ] [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e4" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "DocumentReference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "DocumentReference" ] ] ) ] [ fhir:context [ fhir:v "DocumentReference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid4" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/DocumentReference/" ] ] [ fhir:value [ fhir:v "uuid4" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "DocumentReference" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "cdatobundle" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ClinicalDocumentToBundle" ] ; ( fhir:variable [ fhir:v "cda" ] [ fhir:v "patient" ] [ fhir:v "composition" ] [ fhir:v "encounter" ] [ fhir:v "bundle" ] [ fhir:v "DocumentReference" ] ) ] ) ] [ fhir:name [ fhir:v "patient" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "recordTarget" ] ; fhir:variable [ fhir:v "recordTarget" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "recPat" ] ; ( fhir:source [ fhir:context [ fhir:v "recordTarget" ] ; fhir:element [ fhir:v "patientRole" ] ; fhir:variable [ fhir:v "patient" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "idfr" ] ; ( fhir:source [ fhir:context [ fhir:v "patient" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "id" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "patient" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "identifier" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "root1" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "root" ] ; fhir:variable [ fhir:v "r" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "r" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext1" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "ext1" ] ] ) ] ) ] [ fhir:name [ fhir:v "assigningAuthorityName" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "assigningAuthorityName" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "assigner" ] ; fhir:variable [ fhir:v "a" ] ] [ fhir:context [ fhir:v "a" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "s" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "record" ] ; ( fhir:source [ fhir:context [ fhir:v "patient" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "id" ] ; fhir:condition [ fhir:v "(root = '2.16.840.1.113883.2.9.4.3.2') or (root = '2.16.840.1.113883.2.9.4.3.7') or (root = '2.16.840.1.113883.2.9.4.3.3') or (root = '2.16.840.1.113883.2.9.4.3.17') or (root = '2.16.840.1.113883.2.9.4.3.18') or (root = '2.16.840.1.113883.2.9.2.10.4.1.1') or (root = '2.16.840.1.113883.2.9.2.20.4.1.1') or (root = '2.16.840.1.113883.2.9.2.30.4.1.1') or (root = '2.16.840.1.113883.2.9.2.41.4.1.1') or (root = '2.16.840.1.113883.2.9.2.42.4.1.1') or (root = '2.16.840.1.113883.2.9.2.50.4.1.1') or (root = '2.16.840.1.113883.2.9.2.60.4.1.1') or (root = '2.16.840.1.113883.2.9.2.70.4.1.1') or (root = '2.16.840.1.113883.2.9.2.80.4.1.1') or (root = '2.16.840.1.113883.2.9.2.90.4.1.1') or (root = '2.16.840.1.113883.2.9.2.100.4.1.1') or (root = '2.16.840.1.113883.2.9.2.110.4.1.1') or (root = '2.16.840.1.113883.2.9.2.120.4.1.1') or (root = '2.16.840.1.113883.2.9.2.130.4.1.1') or (root = '2.16.840.1.113883.2.9.2.140.4.1.1') or (root = '2.16.840.1.113883.2.9.2.150.4.1.1') or (root = '2.16.840.1.113883.2.9.2.160.4.1.1') or (root = '2.16.840.1.113883.2.9.2.170.4.1.1') or (root = '2.16.840.1.113883.2.9.2.180.4.1.1') or (root = '2.16.840.1.113883.2.9.2.190.4.1.1') or (root = '2.16.840.1.113883.2.9.2.200.4.1.1') or (root = '2.16.840.1.113883.2.9.2.10.4.1') or (root = '2.16.840.1.113883.2.9.2.20.4.1') or (root = '2.16.840.1.113883.2.9.2.30.4.1') or (root = '2.16.840.1.113883.2.9.2.41.4.1') or (root = '2.16.840.1.113883.2.9.2.42.4.1') or (root = '2.16.840.1.113883.2.9.2.50.4.1') or (root = '2.16.840.1.113883.2.9.2.60.4.1') or (root = '2.16.840.1.113883.2.9.2.70.4.1') or (root = '2.16.840.1.113883.2.9.2.80.4.1') or (root = '2.16.840.1.113883.2.9.2.90.4.1') or (root = '2.16.840.1.113883.2.9.2.100.4.1') or (root = '2.16.840.1.113883.2.9.2.110.4.1') or (root = '2.16.840.1.113883.2.9.2.120.4.1') or (root = '2.16.840.1.113883.2.9.2.130.4.1') or (root = '2.16.840.1.113883.2.9.2.140.4.1') or (root = '2.16.840.1.113883.2.9.2.150.4.1') or (root = '2.16.840.1.113883.2.9.2.160.4.1') or (root = '2.16.840.1.113883.2.9.2.170.4.1') or (root = '2.16.840.1.113883.2.9.2.180.4.1') or (root = '2.16.840.1.113883.2.9.2.190.4.1') or (root = '2.16.840.1.113883.2.9.2.200.4.1') or (root = '2.16.840.1.113883.2.9.4.3.15')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "UUID" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "requestPAT" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Patient?identifier=" ] ] [ fhir:value [ fhir:v "ext" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "ClinicalDocumentToBundle" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "cda" ] ; fhir:type [ fhir:v "ClinicalDocument" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "composition" ] ; fhir:type [ fhir:v "Composition" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "DocumentReference" ] ; fhir:type [ fhir:v "DocumentReference" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "id" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:transform [ fhir:v "uuid" ] ] ) ] [ fhir:name [ fhir:v "identifier" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "type" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "type" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "transaction" ] ] ) ] ) ] [ fhir:name [ fhir:v "date" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "timestamp" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "timestamp.now()" ] ] ) ] ) ] [ fhir:name [ fhir:v "composition" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ClinicalDocumentComposition" ] ; ( fhir:variable [ fhir:v "cda" ] [ fhir:v "composition" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "bundle" ] [ fhir:v "DocumentReference" ] ) ] ) ] [ fhir:name [ fhir:v "diagnostic" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e" ] ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "diagnosticReport" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "DiagnosticReport" ] ] ) ] [ fhir:context [ fhir:v "diagnosticReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/DiagnosticReport/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "DiagnosticReport" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "diagnosticCode" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "diagnosticReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "stats" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "diagnosticReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "registered" ] ] ) ] ) ] [ fhir:name [ fhir:v "component" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "component" ] ; fhir:variable [ fhir:v "component" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "body" ] ; ( fhir:source [ fhir:context [ fhir:v "component" ] ; fhir:element [ fhir:v "structuredBody" ] ; fhir:variable [ fhir:v "body" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "component" ] ; ( fhir:source [ fhir:context [ fhir:v "body" ] ; fhir:element [ fhir:v "component" ] ; fhir:variable [ fhir:v "component" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "section" ] ; ( fhir:source [ fhir:context [ fhir:v "component" ] ; fhir:element [ fhir:v "section" ] ; fhir:variable [ fhir:v "srcSection" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "srcSection" ] ; fhir:element [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "composition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "section" ] ; fhir:variable [ fhir:v "tgtSection" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ClinicalDocumentSection" ] ; ( fhir:variable [ fhir:v "cda" ] [ fhir:v "srcSection" ] [ fhir:v "patient" ] [ fhir:v "tgtSection" ] [ fhir:v "bundle" ] [ fhir:v "encounter" ] [ fhir:v "diagnosticReport" ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "ClinicalDocumentSection" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "cda" ] ; fhir:type [ fhir:v "ClinicalDocument" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "Section" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "enc" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "dReport" ] ; fhir:type [ fhir:v "DiagnosticReport" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "title" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "title" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "title" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "t.dataString" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/DiagnosticReport/' + %dReport.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "entry" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entry" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "cdaText" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "cdaText" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "fhirText" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "narrativeStatus" ] ; ( fhir:source [ fhir:context [ fhir:v "cdaText" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "fhirText" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "generated" ] ] ) ] ) ] [ fhir:name [ fhir:v "narrativeText" ] ; ( fhir:source [ fhir:context [ fhir:v "cdaText" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "fhirText" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "div" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "t" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "dreport" ] ; ( fhir:source [ fhir:context [ fhir:v "entry" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "DiagnosticReportFunction" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "entry" ] [ fhir:v "dReport" ] [ fhir:v "bundle" ] [ fhir:v "enc" ] [ fhir:v "patient" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "narrative" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "src.entry.exists().not()" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "DiagnosticReportFunction" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "cda" ] [ fhir:v "dReport" ] [ fhir:v "bundle" ] [ fhir:v "enc" ] [ fhir:v "patient" ] ) ] ) ] [ fhir:name [ fhir:v "component" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "component" ] ; fhir:variable [ fhir:v "component" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "section" ] ; ( fhir:source [ fhir:context [ fhir:v "component" ] ; fhir:element [ fhir:v "section" ] ; fhir:variable [ fhir:v "sec" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "section" ] ; fhir:variable [ fhir:v "tgtSection" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ClinicalDocumentSection" ] ; ( fhir:variable [ fhir:v "cda" ] [ fhir:v "sec" ] [ fhir:v "patient" ] [ fhir:v "tgtSection" ] [ fhir:v "bundle" ] [ fhir:v "enc" ] [ fhir:v "dReport" ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "DiagnosticReportFunction" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "section" ] ; fhir:type [ fhir:v "section" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "entry" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "dReport" ] ; fhir:type [ fhir:v "DiagnosticReport" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "entryObs" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "QuesitoDiagnostico" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '29299-5'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e1" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs1.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs1" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "StoriaClinica1" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '11329-0'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs2" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs2.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "STatusobse" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "final" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "codeS" ] ; ( fhir:source [ fhir:context [ fhir:v "s" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "cos" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "cos" ] ] [ fhir:value [ fhir:v "#OBSstatus" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "subSection" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "component" ] ; fhir:variable [ fhir:v "component" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "section" ] ; ( fhir:source [ fhir:context [ fhir:v "component" ] ; fhir:element [ fhir:v "section" ] ; fhir:variable [ fhir:v "section" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "sectionCode" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "code = '10160-0'" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "entry" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entry" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "creat" ] ; ( fhir:source [ fhir:context [ fhir:v "entry" ] ; fhir:element [ fhir:v "substanceAdministration" ] ; fhir:variable [ fhir:v "subAdmin" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e11" ] ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medicationstatement" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationStatement" ] ] ) ] [ fhir:context [ fhir:v "medicationstatement" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid11" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/MedicationStatement/" ] ] [ fhir:value [ fhir:v "uuid11" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationStatement" ] ] ) ] [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/MedicationStatement/' + %medicationstatement.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "MedicationStatement" ] ; ( fhir:variable [ fhir:v "subAdmin" ] [ fhir:v "medicationstatement" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "bundle" ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "conditionAllergie" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "code = '48765-2'" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "section" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e4" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "list1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "List" ] ] ) ] [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid4" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/List/" ] ] [ fhir:value [ fhir:v "uuid4" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "List" ] ] ) ] [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "focus" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/List/' + %list1.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "listatus" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "current" ] ] ) ] ) ] [ fhir:name [ fhir:v "lstmod" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "mode" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "working" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "entryList" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entryList1" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "entryAll" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entry" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "allergy" ] ; ( fhir:source [ fhir:context [ fhir:v "entry" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act1" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e5" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "allergy" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "AllergyIntolerance" ] ] ) ] [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid5" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/AllergyIntolerance/" ] ] [ fhir:value [ fhir:v "uuid5" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "AllergyIntolerance" ] ] ) ] [ fhir:context [ fhir:v "entryList1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "item" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/AllergyIntolerance/' + %allergy.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "allergyFunction" ] ; ( fhir:variable [ fhir:v "act1" ] [ fhir:v "allergy" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entry" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entry" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "condition" ] ; ( fhir:source [ fhir:context [ fhir:v "entry" ] ; fhir:element [ fhir:v "observation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e3" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "condition" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Condition" ] ] ) ] [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid3" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Condition/" ] ] [ fhir:value [ fhir:v "uuid3" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Condition" ] ] ) ] [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "focus" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Condition/' + %condition.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ConditionFunction" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "condition" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "organizer" ] ; ( fhir:source [ fhir:context [ fhir:v "entry" ] ; fhir:element [ fhir:v "organizer" ] ; fhir:variable [ fhir:v "organizer" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "List" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e11" ] ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "list11" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "List" ] ] ) ] [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid11" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/List/" ] ] [ fhir:value [ fhir:v "uuid11" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "List" ] ] ) ] [ fhir:context [ fhir:v "obs2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "focus" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/List/' + %list11.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "liststat" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "current" ] ] ) ] ) ] [ fhir:name [ fhir:v "listmd" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "mode" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "working" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "org" ] ; ( fhir:source [ fhir:context [ fhir:v "organizer" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "list11" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "entryList2" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "family" ] ; ( fhir:source [ fhir:context [ fhir:v "organizer" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e12" ] ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "familyMember" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "FamilyMemberHistory" ] ] ) ] [ fhir:context [ fhir:v "familyMember" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid12" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/FamilyMemberHistory/" ] ] [ fhir:value [ fhir:v "uuid12" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "FamilyMemberHistory" ] ] ) ] [ fhir:context [ fhir:v "entryList2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "item" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/FamilyMemberHistory/' + %familyMember.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "FamilyMemberFunction" ] ; ( fhir:variable [ fhir:v "organizer" ] [ fhir:v "familyMember" ] [ fhir:v "patient" ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "PrecedentiEsamiEseguiti" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '30954-2'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e4" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs4" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid4" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e4" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid4" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs4.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs4" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "Diagnosi" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '29548-5'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e5" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs5" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid5" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid5" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs5.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs5" ] [ fhir:v "bundle" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryAct" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "Prestazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '62387-6'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "type" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "encounter" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "type" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "period" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "encounter" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "period" ] ; fhir:variable [ fhir:v "period" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "val" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "period" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "start" ] ; fhir:variable [ fhir:v "start" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "start" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "proceduraMadre" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e10" ] ] [ fhir:context [ fhir:v "e10" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e10" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "procedureRes" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid10" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e10" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Procedure/" ] ] [ fhir:value [ fhir:v "uuid10" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "encounter" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reasonReference" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Procedure/' + %procedureRes.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "status1" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "status2" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "Relationship" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRel" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "procedurePrestazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRel" ] ; fhir:element [ fhir:v "procedure" ] ; fhir:variable [ fhir:v "proc" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e9" ] ] [ fhir:context [ fhir:v "e9" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e9" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "procedure2" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "procedure2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid9" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e9" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Procedure/" ] ] [ fhir:value [ fhir:v "uuid9" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Procedure/' + %procedure2.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Procedure" ] ; ( fhir:variable [ fhir:v "proc" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "procedure2" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "farmacPrestazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRel" ] ; fhir:element [ fhir:v "substanceAdministration" ] ; fhir:variable [ fhir:v "subAdmin" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e8" ] ] [ fhir:context [ fhir:v "e8" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e8" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medAdmin" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationAdministration" ] ] ) ] [ fhir:context [ fhir:v "medAdmin" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid8" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e8" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/MedicationAdministration/" ] ] [ fhir:value [ fhir:v "uuid8" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationAdministration" ] ] ) ] [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/MedicationAdministration/' + %medAdmin.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "MedicationAdministration" ] ; ( fhir:variable [ fhir:v "subAdmin" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "medAdmin" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "osservazioniPrestazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRel" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "entryRobs" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e7" ] ] [ fhir:context [ fhir:v "e7" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e7" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs7" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs7" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid7" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e7" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid7" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs7.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ObservationPrest" ] ; ( fhir:variable [ fhir:v "entryRobs" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs7" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "procedureGenerichePrestazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRel" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act2" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e6" ] ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "procedure3" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "procedure3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid6" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Procedure/" ] ] [ fhir:value [ fhir:v "uuid6" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Procedure" ] ] ) ] [ fhir:context [ fhir:v "procedureRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Procedure/' + %procedure3.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Procedure" ] ; ( fhir:variable [ fhir:v "act2" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "procedure3" ] [ fhir:v "bundle" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Followup" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '80615-8'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e12" ] ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs12" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid12" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e12" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid12" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs12.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "act" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs12" ] [ fhir:v "bundle" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "substanceadmin" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "substanceAdministration" ] ; fhir:variable [ fhir:v "substanceadmin" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "TerapiaFarmacologicaConsigliata" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "code.code = '93341-6'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e6" ] ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medre1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "medre1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid6" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e6" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/MedicationRequest/" ] ] [ fhir:value [ fhir:v "uuid6" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "basedOn" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/MedicationRequest/' + %medre1.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "MedicationRequest" ] ; ( fhir:variable [ fhir:v "substanceadmin" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "medre1" ] [ fhir:v "bundle" ] ) ] ) ] ) ; fhir:documentation [ fhir:v "src.substanceAdministration" ] ] [ fhir:name [ fhir:v "whereCond" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "section.entry.exists().not()" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "allergyAct" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "(code.code = '48765-2')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs1.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "STatusobse" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "final" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "codeS" ] ; ( fhir:source [ fhir:context [ fhir:v "s" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "cos" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "cos" ] ] [ fhir:value [ fhir:v "#OBSstatus" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "allergytext" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e5" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "allergy" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "AllergyIntolerance" ] ] ) ] [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid5" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e5" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/AllergyIntolerance/" ] ] [ fhir:value [ fhir:v "uuid5" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "AllergyIntolerance" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "focus" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/AllergyIntolerance/' + %allergy.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "patient" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "clinicalStatus" ] ; fhir:variable [ fhir:v "clinicalStatus" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "clinicalStatus" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Coding" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "active" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "narrative" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "allergy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "textNote" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "EDstring" ] ; ( fhir:variable [ fhir:v "t" ] [ fhir:v "textNote" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "MedicationRequest" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "(code.code = '93341-6')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "txtsec" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e13" ] ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs13" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid13" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/MedicationRequest/" ] ] [ fhir:value [ fhir:v "uuid13" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "basedOn" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/MedicationRequest/' + %obs13.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "intent" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "intent" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "order" ] ] ) ] ) ] [ fhir:name [ fhir:v "st" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "textNote" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "EDstring" ] ; ( fhir:variable [ fhir:v "t" ] [ fhir:v "textNote" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "medication" ] ; fhir:variable [ fhir:v "code" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "string" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "code" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "NonConclusion" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "(code.code = '55110-1').not() and (code.code = '93341-6').not() and (code.code = '48765-2').not()" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "txtsec" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e13" ] ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs13" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid13" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid13" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "result" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs13.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "obsst" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "preliminary" ] ] ) ] ) ] [ fhir:name [ fhir:v "obscde" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "statusS" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "final" ] ] ) ] ) ] [ fhir:name [ fhir:v "narrative" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "obs13" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "textNote" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "EDstring" ] ; ( fhir:variable [ fhir:v "t" ] [ fhir:v "textNote" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "conclusion" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:condition [ fhir:v "(code.code = '55110-1')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "conc" ] ; ( fhir:source [ fhir:context [ fhir:v "section" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "t" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dReport" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "conclusion" ] ; fhir:variable [ fhir:v "textConclusion" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "EDstring" ] ; ( fhir:variable [ fhir:v "t" ] [ fhir:v "textConclusion" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Observation" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "cda" ] ; fhir:type [ fhir:v "observation" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "ob" ] ; fhir:type [ fhir:v "Observation" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "Stats" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "final" ] ] ) ] ) ] [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "INT" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "int" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "int.value" ] ] ) ] ) ; fhir:documentation [ fhir:v "value datatype" ] ] [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "ST" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "st" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "string" ] ] ) ] [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "st.dataString" ] ] ) ] ) ] [ fhir:name [ fhir:v "boolean" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "BL" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "boolean" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "boolean.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "val" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "CE" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "val" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "ce" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "originalText" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "originalText" ] ; fhir:variable [ fhir:v "originalText" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "originalText" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "translation" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "translation" ] ; fhir:variable [ fhir:v "translation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "qualifier" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "qualifier" ] ; fhir:variable [ fhir:v "qualifier" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "qualifier" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "val" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "CD" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "val" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "ce" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "originalText" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "originalText" ] ; fhir:variable [ fhir:v "originalText" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "originalText" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "translation" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "translation" ] ; fhir:variable [ fhir:v "translation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "qualifier" ] ; ( fhir:source [ fhir:context [ fhir:v "translation" ] ; fhir:element [ fhir:v "qualifier" ] ; fhir:variable [ fhir:v "qualifier" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "qualifier" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ce" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] [ fhir:name [ fhir:v "codeSystem" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "codeSystem" ] ; fhir:variable [ fhir:v "system" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "system" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "displayName" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "valueQuantity" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:type [ fhir:v "PQ" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "val" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "quantity" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "quantity" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Quantity" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "quantity" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "value" ] ] ) ] ) ] [ fhir:name [ fhir:v "unit" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "unit" ] ; fhir:variable [ fhir:v "unit" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "quantity" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unit" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "value1" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(value.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "effective" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(low.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "effective" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "cda" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "codeS" ] ; ( fhir:source [ fhir:context [ fhir:v "s" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "cos" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ob" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "cos" ] ] [ fhir:value [ fhir:v "#OBSstatus" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "ConditionFunction" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "cdaElement" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "Condition" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "category" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "verifstatus" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "stscode" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "verificationStatus" ] ; fhir:variable [ fhir:v "verifstatus" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "stscode" ] ; fhir:variable [ fhir:v "codeS" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "verifstatus" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Coding" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "codeS" ] ; fhir:element [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "confirmed" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "codeS" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://terminology.hl7.org/CodeSystem/condition-ver-status" ] ] ) ] ) ] [ fhir:name [ fhir:v "display" ] ; ( fhir:source [ fhir:context [ fhir:v "codeS" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Confirmed" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "entryR" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "EntryRelObsevation" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "obsentry" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observation" ] ; ( fhir:source [ fhir:context [ fhir:v "obsentry" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "code = '89261-2'" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observation" ] ; ( fhir:source [ fhir:context [ fhir:v "obsentry" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "evidence" ] ; fhir:variable [ fhir:v "evidence" ] ] [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e1" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obsy" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obsy" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "evidence" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "detail" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obsy.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "obsentry" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obsy" ] [ fhir:v "bundle" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "clinicalStatus2" ] ; ( fhir:source [ fhir:context [ fhir:v "obsentry" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "code = '33999-4'" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "clinicalstatus" ] ; ( fhir:source [ fhir:context [ fhir:v "obsentry" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "clinicalStatus" ] ; fhir:variable [ fhir:v "clinicalstatus" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:variable [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "clinicalstatus" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Coding" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:condition [ fhir:v "(code = 'LA9041-0')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "resolved" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:condition [ fhir:v "(code = 'LA18632-2')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "inactive" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:condition [ fhir:v "(code = 'LA16666-2')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "active" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://terminology.hl7.org/CodeSystem/condition-clinical" ] ] ) ] ) ] [ fhir:name [ fhir:v "display" ] ; ( fhir:source [ fhir:context [ fhir:v "val" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "obsentry" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "clinicalstatus" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Procedure" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "procedure" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "Procedure" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "status1" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "status2" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "id" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "value1" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(value.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "performed" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(low.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "performed" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "methodCode" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "methodCode" ] ; fhir:variable [ fhir:v "methodCode" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext1" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "ITMethodExt" ] ; ( fhir:variable [ fhir:v "methodCode" ] [ fhir:v "ext1" ] ) ] ) ] [ fhir:name [ fhir:v "participant" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "participant" ] ; fhir:variable [ fhir:v "participant" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "participantRole" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ; fhir:element [ fhir:v "participantRole" ] ; fhir:variable [ fhir:v "participantRole" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "performer" ] ; fhir:variable [ fhir:v "performer" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "device" ] ; ( fhir:source [ fhir:context [ fhir:v "participantRole" ] ; fhir:element [ fhir:v "playingDevice" ] ; fhir:variable [ fhir:v "device" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "deviceRes" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Device/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "performer" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "actor" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Device/' + %deviceRes.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manufacturer" ] ; ( fhir:source [ fhir:context [ fhir:v "device" ] ; fhir:element [ fhir:v "manufacturerModelName" ] ; fhir:variable [ fhir:v "manufacturerModelName" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manuf" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturerModelName" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "displayName" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "manufacturer" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "displayName" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "device" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "type" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryRelProcedure" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "Parametri" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e3" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid3" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid3" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs1.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs1" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "act" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "ITMethodExt" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "ext" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "url" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ext" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://hl7.org/fhir/StructureDefinition/procedure-method" ] ] ) ] ) ] [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ext" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "CECodeableConcept" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "value" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "MedicationAdministration" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "substanceAdministration" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "MedicationAdministration" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "context" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "status1" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "status2" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "id" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "value1" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(value.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "effective" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(low.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "effective" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "dosage" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosage" ] ; fhir:variable [ fhir:v "dosage" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "route" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "routeCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "route" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "repQ" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "repeatNumber" ] ; fhir:variable [ fhir:v "repeatNumber" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "rate" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "SimpleQuantity" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "PQQuantity" ] ; ( fhir:variable [ fhir:v "repeatNumber" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "site" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "approachSiteCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "site" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "site" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "targetSiteCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "site" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] [ fhir:name [ fhir:v "medication" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "consumable" ] ; fhir:variable [ fhir:v "consumable" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e1" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medication" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Medication" ] ] ) ] [ fhir:context [ fhir:v "medication" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Medication/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Medication" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "medication" ] ; fhir:variable [ fhir:v "medref" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "medref" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Medication/' + %medication.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Medication" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "medication" ] [ fhir:v "patient" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "participant" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "participant" ] ; fhir:variable [ fhir:v "participant" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "participantRole" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ; fhir:element [ fhir:v "participantRole" ] ; fhir:variable [ fhir:v "participantRole" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "performer" ] ; fhir:variable [ fhir:v "performer" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "device" ] ; ( fhir:source [ fhir:context [ fhir:v "participantRole" ] ; fhir:element [ fhir:v "device" ] ; fhir:variable [ fhir:v "device" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "deviceRes" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Device/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "performer" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "actor" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Device/' + %deviceRes.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manufacturer" ] ; ( fhir:source [ fhir:context [ fhir:v "device" ] ; fhir:element [ fhir:v "ManufacturerModelName" ] ; fhir:variable [ fhir:v "ManufacturerModelName" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manuf" ] ; ( fhir:source [ fhir:context [ fhir:v "ManufacturerModelName" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "manufacturer" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryRelMedication" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "Parametri" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e3" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid3" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid3" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "partOf" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs1.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs1" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "act" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "medRequ" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "(src.doseQuantity.exists() or src.rateQuantity.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e1" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medicationRq" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "medicationRq" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/MedicationRequest/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "MedicationRequest" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/MedicationRequest/' + %medicationRq.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "MedicationRequest" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "medicationRq" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "ObservationPrest" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "observation" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "Observation" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "codeS" ] ; ( fhir:source [ fhir:context [ fhir:v "s" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "cos" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "cos" ] ] [ fhir:value [ fhir:v "#OBSstatus" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "id" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "value1" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(value.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "perfomed" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ; fhir:condition [ fhir:v "(low.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "perfomed" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "methodCode" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "methodCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "participant" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "participant" ] ; fhir:variable [ fhir:v "participant" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "participantRole" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ; fhir:element [ fhir:v "participantRole" ] ; fhir:variable [ fhir:v "participantRole" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "device" ] ; ( fhir:source [ fhir:context [ fhir:v "participantRole" ] ; fhir:element [ fhir:v "device" ] ; fhir:variable [ fhir:v "device" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e2" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "deviceRes" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid2" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e2" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Device/" ] ] [ fhir:value [ fhir:v "uuid2" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Device" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "device" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Device/' + %deviceRes.id" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manufacturer" ] ; ( fhir:source [ fhir:context [ fhir:v "device" ] ; fhir:element [ fhir:v "ManufacturerModelName" ] ; fhir:variable [ fhir:v "ManufacturerModelName" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manuf" ] ; ( fhir:source [ fhir:context [ fhir:v "ManufacturerModelName" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "deviceRes" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "manufacturer" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryRelOsservazioni" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "Parametri" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e3" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "obs1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "obs1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid3" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e3" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Observation/" ] ] [ fhir:value [ fhir:v "uuid3" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Observation" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "hasMember" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Observation/' + %obs1.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Observation" ] ; ( fhir:variable [ fhir:v "observation" ] [ fhir:v "patient" ] [ fhir:v "encounter" ] [ fhir:v "obs1" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "act" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "MedicationRequest" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "substanceAdministration" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "MedicationRequest" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ; fhir:documentation [ fhir:v "default + mandatory" ] ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "intent" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "intent" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "order" ] ] ) ] ) ] [ fhir:name [ fhir:v "st" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "status" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "sc" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "codeS" ] ; ( fhir:source [ fhir:context [ fhir:v "sc" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "cos" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "cos" ] ] [ fhir:value [ fhir:v "#MedicationStatusMap" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "txt" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "text" ] ; ( fhir:source [ fhir:context [ fhir:v "txt" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "period" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:type [ fhir:v "IVL_TS" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosageInstruction" ] ; fhir:variable [ fhir:v "dosage" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Dosage" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "timing" ] ; ( fhir:source [ fhir:context [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "timing" ] ; fhir:variable [ fhir:v "timing" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Timing" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "rep" ] ; ( fhir:source [ fhir:context [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "timing" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "repeat" ] ; fhir:variable [ fhir:v "rep" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value1" ] ; ( fhir:source [ fhir:context [ fhir:v "eff" ] ; fhir:variable [ fhir:v "eff" ] ; fhir:condition [ fhir:v "(value.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "rep" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "bounds" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "eff" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "eff" ] ; fhir:variable [ fhir:v "eff" ] ; fhir:condition [ fhir:v "(low.exists())" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "rep" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "bounds" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "eff" ] [ fhir:v "value" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "period" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:type [ fhir:v "EIVL_TS" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effe" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosageInstruction" ] ; fhir:variable [ fhir:v "dosage" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Dosage" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "timing" ] ; ( fhir:source [ fhir:context [ fhir:v "effe" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "timing" ] ; fhir:variable [ fhir:v "timing" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Timing" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "rep" ] ; ( fhir:source [ fhir:context [ fhir:v "effe" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "timing" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "repeat" ] ; fhir:variable [ fhir:v "rep" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "eventCode" ] ; ( fhir:source [ fhir:context [ fhir:v "effe" ] ; fhir:element [ fhir:v "eventCode" ] ; fhir:variable [ fhir:v "ev" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "rep" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "when" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "ev.code" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "tim" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:type [ fhir:v "IVL_TS" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosageInstruction" ] ; fhir:variable [ fhir:v "dosage" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Dosage" ] ] ) ] [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "timing" ] ; fhir:variable [ fhir:v "timing" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Timing" ] ] ) ] [ fhir:context [ fhir:v "timing" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "event" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "eff.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "eff" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:type [ fhir:v "PIVL_TS" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosageInstruction" ] ; fhir:variable [ fhir:v "dosage" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Dosage" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "cod" ] ; ( fhir:source [ fhir:context [ fhir:v "eff" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosage" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "timing" ] ; fhir:variable [ fhir:v "timing" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Timing" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "periodTiming" ] ; ( fhir:variable [ fhir:v "eff" ] [ fhir:v "timing" ] ) ] ) ] ) ] [ fhir:name [ fhir:v "condition" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "(src.doseQuantity.exists() or src.rateQuantity.exists())" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "dosageIn" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dosageInstruction" ] ; fhir:variable [ fhir:v "dosageInstruction" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Dosage" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "doseQuantity" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "doseQuantity" ] ; fhir:variable [ fhir:v "doseQuant" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "ot" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ; fhir:element [ fhir:v "originalText" ] ; fhir:variable [ fhir:v "ot" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "ot" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] [ fhir:name [ fhir:v "dosageRate" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "doseAndRate" ] ; fhir:variable [ fhir:v "dosageRate" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "d" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageRate" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dose" ] ; fhir:variable [ fhir:v "d" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Range" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "d" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "l" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "SimpleQuantity" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "lo" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "l" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "lo.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "lo" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "l" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "lo.unit" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "d" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "h" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "SimpleQuantity" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "high" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "hi" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "h" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "hi.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "high" ] ; ( fhir:source [ fhir:context [ fhir:v "doseQuant" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "hi" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "h" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "hi.unit" ] ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "rate" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "rateQuantity" ] ; fhir:variable [ fhir:v "rateQuantity" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "ot" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ; fhir:element [ fhir:v "originalText" ] ; fhir:variable [ fhir:v "ot" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "ot" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] [ fhir:name [ fhir:v "dosageRate" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "doseAndRate" ] ; fhir:variable [ fhir:v "dosageRate" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "r" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageRate" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "rate" ] ; fhir:variable [ fhir:v "d" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Range" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "d" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "l" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "SimpleQuantity" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "lo" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "l" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "lo.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "lo" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "l" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "lo.unit" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "high" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "d" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "h" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "SimpleQuantity" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "high" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "hi" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "h" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "hi.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "high" ] ; ( fhir:source [ fhir:context [ fhir:v "rateQuantity" ] ; fhir:element [ fhir:v "high" ] ; fhir:variable [ fhir:v "hi" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "h" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "hi.unit" ] ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "route" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "routeCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "route" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "site" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "approachSiteCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "site" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "site" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "targetSiteCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dosageInstruction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "site" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "medication" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "consumable" ] ; fhir:variable [ fhir:v "consumable" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e1" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "POST" ] ] ) ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "medication" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Medication" ] ] ) ] [ fhir:context [ fhir:v "medication" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid1" ] ; fhir:transform [ fhir:v "uuid" ] ] [ fhir:context [ fhir:v "e1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Medication/" ] ] [ fhir:value [ fhir:v "uuid1" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Medication" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "medication" ] ; fhir:variable [ fhir:v "medref" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "medref" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Medication/' + %medication.id" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Medication" ] ; ( fhir:variable [ fhir:v "src" ] [ fhir:v "medication" ] [ fhir:v "patient" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "entryR" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "supply" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship" ] ; fhir:element [ fhir:v "supply" ] ; fhir:variable [ fhir:v "supply" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "dispenseRequest" ] ; fhir:variable [ fhir:v "dispenseRequest" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "quantity" ] ; ( fhir:source [ fhir:context [ fhir:v "supply" ] ; fhir:element [ fhir:v "quantity" ] ; fhir:variable [ fhir:v "quantityCDA" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "dispenseRequest" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "quantity" ] ; fhir:variable [ fhir:v "quantityFHIR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "quantityCDA" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "quantityFHIR" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "quantityCDA.value" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Partecipant" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "participant" ] ; fhir:variable [ fhir:v "participant" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "function" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "Practitioner" ] ; ( fhir:variable [ fhir:v "participant" ] [ fhir:v "tgt" ] [ fhir:v "bundle" ] ) ] ) ] [ fhir:name [ fhir:v "autor" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "authoredOn" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "periodTiming" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "effectiveTime" ] ; fhir:type [ fhir:v "PIVL_TS" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "timing" ] ; fhir:type [ fhir:v "Timing" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "repeat" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "timing" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "repeat" ] ; fhir:variable [ fhir:v "r" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "period" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ; fhir:element [ fhir:v "period" ] ; fhir:variable [ fhir:v "p" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "r" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "period" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "p.value" ] ] ) ] ) ] [ fhir:name [ fhir:v "period" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ; fhir:element [ fhir:v "period" ] ; fhir:variable [ fhir:v "p" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "r" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "periodUnit" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "p.unit" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Medication" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "cda" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "Medication" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "consumable" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "consumable" ] ; fhir:variable [ fhir:v "consumable" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "product" ] ; ( fhir:source [ fhir:context [ fhir:v "consumable" ] ; fhir:element [ fhir:v "manufacturedProduct" ] ; fhir:variable [ fhir:v "manufacturedProduct" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "material" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedProduct" ] ; fhir:element [ fhir:v "manufacturedMaterial" ] ; fhir:variable [ fhir:v "manufacturedMaterial" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "CE" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedMaterial" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "form" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "administrationUnitCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "form" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryR" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "obs" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "ingredient" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "displayName = 'Grammatura'" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "ingredient" ] ; fhir:variable [ fhir:v "ingredient" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "consumable" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "consumable" ] ; fhir:variable [ fhir:v "consumable" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "product" ] ; ( fhir:source [ fhir:context [ fhir:v "consumable" ] ; fhir:element [ fhir:v "manufacturedProduct" ] ; fhir:variable [ fhir:v "manufacturedProduct" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "material" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedProduct" ] ; fhir:element [ fhir:v "manufacturedMaterial" ] ; fhir:variable [ fhir:v "manufacturedMaterial" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "CE" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedMaterial" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ingredient" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "item" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "CECodeableConcept" ] ; ( fhir:variable [ fhir:v "code" ] [ fhir:v "value" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "strenght" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "ingredient" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "strength" ] ; fhir:variable [ fhir:v "strength" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "numerator" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "strength" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "numerator" ] ; fhir:variable [ fhir:v "numerator" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valueN" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "numerator" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "value.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "denominator" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "strength" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "denominator" ] ; fhir:variable [ fhir:v "denominator" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valueD" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "denominator" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "1"^^xsd:integer ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "quantita" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "code" ] ; fhir:condition [ fhir:v "displayName = 'Quantità nella Confezione'" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "amount" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "amount" ] ; fhir:variable [ fhir:v "amount" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "numerator" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "amount" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "numerator" ] ; fhir:variable [ fhir:v "numerator" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valueN" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "numerator" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "value.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "denominator" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "amount" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "denominator" ] ; fhir:variable [ fhir:v "denominator" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valueD" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "denominator" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "1"^^xsd:integer ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "MedicationStatement" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "subAdmin" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "MedicationStatement" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "Patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "Encounter" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "statusCode" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "notpresent" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:condition [ fhir:v "statusCode.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unknown" ] ] ) ] ) ] [ fhir:name [ fhir:v "consumable" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "consumable" ] ; fhir:variable [ fhir:v "consumable" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "product" ] ; ( fhir:source [ fhir:context [ fhir:v "consumable" ] ; fhir:element [ fhir:v "manufacturedProduct" ] ; fhir:variable [ fhir:v "manufacturedProduct" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "material" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedProduct" ] ; fhir:element [ fhir:v "manufacturedMaterial" ] ; fhir:variable [ fhir:v "manufacturedMaterial" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "CE" ] ; ( fhir:source [ fhir:context [ fhir:v "manufacturedMaterial" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "medication" ] ; fhir:variable [ fhir:v "ce" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "CodeableConcept" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "CECodeableConcept" ] ; ( fhir:variable [ fhir:v "code" ] [ fhir:v "ce" ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "FamilyMemberFunction" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "organizer" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "FamilyMemberHistory" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "patient" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "patReference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "patient" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "statusCode" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "date" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "date" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "date" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "relationship" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "subject" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "relatedSub" ] ; ( fhir:source [ fhir:context [ fhir:v "subject" ] ; fhir:element [ fhir:v "relatedSubject" ] ; fhir:variable [ fhir:v "relatedSubject" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "relationshipCode" ] ; ( fhir:source [ fhir:context [ fhir:v "relatedSubject" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "relationship" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "subject" ] ; ( fhir:source [ fhir:context [ fhir:v "relatedSubject" ] ; fhir:element [ fhir:v "subject" ] ; fhir:variable [ fhir:v "subject" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "sex" ] ; fhir:variable [ fhir:v "sex" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "subject" ] ; fhir:element [ fhir:v "administrativeGenderCode" ] ; fhir:variable [ fhir:v "administrativeGenderCode" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "sex" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "gender" ] ; ( fhir:source [ fhir:context [ fhir:v "administrativeGenderCode" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "sexCode" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "sexCode" ] ] [ fhir:value [ fhir:v "#cm-v3-administrative-gender" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "administrativeGenderCode" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://hl7.org/fhir/administrative-gender" ] ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "component" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "component" ] ; fhir:variable [ fhir:v "component" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "condition" ] ; fhir:variable [ fhir:v "condition" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observation" ] ; ( fhir:source [ fhir:context [ fhir:v "component" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "statusCode" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "statusCode" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "status" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "cont" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:condition [ fhir:v "observation.effectiveTime.exists()" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "effttemp" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "condition" ] ; fhir:variable [ fhir:v "condition" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "codeable" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "outcome" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "efft" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "period" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "val" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "period" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "start" ] ; fhir:variable [ fhir:v "start" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "start" ] ) ] ) ] ) ] ) ] ) ; fhir:documentation [ fhir:v "observation.effectiveTime as effectiveTime -> condition.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";" ] ] [ fhir:name [ fhir:v "codeable" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "outcome" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "EntryRel" ] ; ( fhir:source [ fhir:context [ fhir:v "observation" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryR" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "obser" ] ; ( fhir:source [ fhir:context [ fhir:v "entryR" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "obs" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "insorgenza" ] ; ( fhir:source [ fhir:context [ fhir:v "obs" ] ; fhir:condition [ fhir:v "(code.code = '35267-4')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "obs" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "condition" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "Age" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Age" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "age" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "valueAge" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "valueAge" ] ] ) ] ) ] [ fhir:name [ fhir:v "unit" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "unit" ] ; fhir:variable [ fhir:v "unit" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unit" ] ] ) ] ) ] [ fhir:name [ fhir:v "unit" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "unit" ] ; fhir:variable [ fhir:v "unit" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unit" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://unitsofmeasure.org" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "death" ] ; ( fhir:source [ fhir:context [ fhir:v "obs" ] ; fhir:condition [ fhir:v "(code.code = '39016-1')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "obs" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "deceased" ] ; fhir:variable [ fhir:v "Age" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Age" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "age" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "valueAge" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "valueAge" ] ] ) ] ) ] [ fhir:name [ fhir:v "unit" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "unit" ] ; fhir:variable [ fhir:v "unit" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unit" ] ] ) ] ) ] [ fhir:name [ fhir:v "unit" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "unit" ] ; fhir:variable [ fhir:v "unit" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "unit" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "unit" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "Age" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://unitsofmeasure.org" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "allergyFunction" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "cdaElement" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "AllergyIntolerance" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "patient" ] ; fhir:type [ fhir:v "patient" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "encounter" ] ; fhir:type [ fhir:v "encounter" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "patient" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Patient/' + %patient.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "encounter" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Encounter/' + %encounter.id" ] ] ) ] ) ] [ fhir:name [ fhir:v "entryrelationship" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship1" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observation" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship1" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation1" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valuePeriod" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Period" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "IVLTSPeriod" ] ; ( fhir:variable [ fhir:v "effectiveTime" ] [ fhir:v "value" ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "code" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "type" ] ; ( fhir:source [ fhir:context [ fhir:v "code" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code1" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "type" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code1" ] ] [ fhir:value [ fhir:v "#AllergyTypeMap" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] [ fhir:name [ fhir:v "category" ] ; ( fhir:source [ fhir:context [ fhir:v "code" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "code1" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "category" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "code1" ] ] [ fhir:value [ fhir:v "#AllergyCategoryMap" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "participant" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "participant" ] ; fhir:variable [ fhir:v "participant" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reaction" ] ; fhir:variable [ fhir:v "reaction" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "entryR2" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship2" ] ; fhir:condition [ fhir:v "(typeCode = 'MFST')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observ2" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship2" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation2" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manifestation" ] ; ( fhir:source [ fhir:context [ fhir:v "observation2" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "reaction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "manifestation" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "observation2" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valuePeriodLow" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "low" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "reaction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "low" ] [ fhir:v "value" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "participantRole" ] ; ( fhir:source [ fhir:context [ fhir:v "participant" ] ; fhir:element [ fhir:v "participantRole" ] ; fhir:variable [ fhir:v "participantRole" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "playingEntity" ] ; ( fhir:source [ fhir:context [ fhir:v "participantRole" ] ; fhir:element [ fhir:v "playingEntity" ] ; fhir:variable [ fhir:v "playingEntity" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reaction" ] ; ( fhir:source [ fhir:context [ fhir:v "playingEntity" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "reaction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "substance" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryR2" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship2" ] ; fhir:condition [ fhir:v "(typeCode = 'MFST')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observ2" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship2" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation2" ] ; fhir:condition [ fhir:v "observation1.participant.exists().not()" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reaction" ] ; fhir:variable [ fhir:v "reaction" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "manifestation" ] ; ( fhir:source [ fhir:context [ fhir:v "observation2" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "reaction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "manifestation" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "low" ] ; ( fhir:source [ fhir:context [ fhir:v "observation2" ] ; fhir:element [ fhir:v "effectiveTime" ] ; fhir:variable [ fhir:v "effectiveTime" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "valuePeriodLow" ] ; ( fhir:source [ fhir:context [ fhir:v "effectiveTime" ] ; fhir:element [ fhir:v "low" ] ; fhir:variable [ fhir:v "low" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "reaction" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "onset" ] ; fhir:variable [ fhir:v "value" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "dateTime" ] ] ) ] ) ; ( fhir:dependent [ fhir:name [ fhir:v "TSDateTime" ] ; ( fhir:variable [ fhir:v "low" ] [ fhir:v "value" ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryR3" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship3" ] ; fhir:condition [ fhir:v "(typeCode = 'SUBJ')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observ3" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship3" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation3" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "criticality" ] ; ( fhir:source [ fhir:context [ fhir:v "observation3" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:element [ fhir:v "code" ] ; fhir:variable [ fhir:v "c" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "criticality" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "c" ] ] [ fhir:value [ fhir:v "#CricalityMap" ] ] [ fhir:value [ fhir:v "code" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "act" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship3" ] ; fhir:element [ fhir:v "act" ] ; fhir:variable [ fhir:v "act" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "note" ] ; fhir:variable [ fhir:v "note" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "note" ] ; ( fhir:source [ fhir:context [ fhir:v "act" ] ; fhir:element [ fhir:v "text" ] ; fhir:variable [ fhir:v "text" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "reference" ] ; ( fhir:source [ fhir:context [ fhir:v "text" ] ; fhir:element [ fhir:v "reference" ] ; fhir:variable [ fhir:v "reference" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "note" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "text" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "reference.value" ] ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "entryR4" ] ; ( fhir:source [ fhir:context [ fhir:v "observation1" ] ; fhir:element [ fhir:v "entryRelationship" ] ; fhir:variable [ fhir:v "entryRelationship4" ] ; fhir:condition [ fhir:v "(typeCode = 'REFR')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "observ4" ] ; ( fhir:source [ fhir:context [ fhir:v "entryRelationship4" ] ; fhir:element [ fhir:v "observation" ] ; fhir:variable [ fhir:v "observation4" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "clinicalStatus" ] ; ( fhir:source [ fhir:context [ fhir:v "observation4" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "value" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "clinicalStatus" ] ; fhir:variable [ fhir:v "clinicalStatus" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "value" ] ; fhir:variable [ fhir:v "valu" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "clinicalStatus" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "coding" ] ; fhir:variable [ fhir:v "coding" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Coding" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "valu" ] ; fhir:condition [ fhir:v "(code = 'LA9041-0')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "resolved" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "valu" ] ; fhir:condition [ fhir:v "(code = 'LA18632-2')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "inactive" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "valu" ] ; fhir:condition [ fhir:v "(code = 'LA16666-2')" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "active" ] ] ) ] ) ] [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "valu" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" ] ] ) ] ) ] [ fhir:name [ fhir:v "display" ] ; ( fhir:source [ fhir:context [ fhir:v "valu" ] ; fhir:element [ fhir:v "displayName" ] ; fhir:variable [ fhir:v "display" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "cast" ] ; ( fhir:parameter [ fhir:value [ fhir:v "display" ] ] [ fhir:value [ fhir:v "string" ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "Practitioner" ] ; fhir:typeMode [ fhir:v "none" ] ; ( fhir:input [ fhir:name [ fhir:v "src" ] ; fhir:type [ fhir:v "participant" ] ; fhir:mode [ fhir:v "source" ] ] [ fhir:name [ fhir:v "tgt" ] ; fhir:type [ fhir:v "MedicationRequest" ] ; fhir:mode [ fhir:v "target" ] ] [ fhir:name [ fhir:v "bundle" ] ; fhir:type [ fhir:v "Bundle" ] ; fhir:mode [ fhir:v "target" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "practitionerCreate" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "bundle" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "entry" ] ; fhir:variable [ fhir:v "e22" ] ] [ fhir:context [ fhir:v "e22" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "request" ] ; fhir:variable [ fhir:v "request" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "BackboneElement" ] ] ) ] [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "method" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "PUT" ] ] ) ] [ fhir:context [ fhir:v "e22" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "resource" ] ; fhir:variable [ fhir:v "practitioner1" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Practitioner" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "resurceCreation" ] ; ( fhir:source [ fhir:context [ fhir:v "src" ] ; fhir:element [ fhir:v "participantRole" ] ; fhir:variable [ fhir:v "practr" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "identifier" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "id" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "identifier" ] ; fhir:variable [ fhir:v "identifier" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "root1" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "root" ] ; fhir:variable [ fhir:v "r" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "translate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "r" ] ] [ fhir:value [ fhir:v "http://hl7.org/fhir/ConceptMap/special-oid2uri" ] ] [ fhir:value [ fhir:v "uri" ] ] ) ] ) ] [ fhir:name [ fhir:v "ext" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "value" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "ext" ] ] ) ] ) ] [ fhir:name [ fhir:v "assigningAuthorityName" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "assigningAuthorityName" ] ; fhir:variable [ fhir:v "s" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "identifier" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "assigner" ] ; fhir:variable [ fhir:v "a" ] ] [ fhir:context [ fhir:v "a" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "display" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "s" ] ] ) ] ) ] [ fhir:name [ fhir:v "r" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "root" ] ; fhir:variable [ fhir:v "r" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "id" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "uuid22" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "r + '-' + ext" ] ] ) ] [ fhir:context [ fhir:v "e22" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "fullUrl" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "https://example/Practitioner/" ] ] [ fhir:value [ fhir:v "uuid22" ] ] ) ] [ fhir:context [ fhir:v "tgt" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "requester" ] ; fhir:variable [ fhir:v "reference" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Reference" ] ] ) ] [ fhir:context [ fhir:v "reference" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "reference" ] ; fhir:transform [ fhir:v "evaluate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "'https://example/Practitioner/' + %practitioner1.id" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "2.16.840.1.113883.2.9.4.3.2" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "id" ] ; fhir:condition [ fhir:v "(root = '2.16.840.1.113883.2.9.4.3.2')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "UUID" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Practitioner?identifier=" ] ] [ fhir:value [ fhir:v "ext" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "diverso" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "id" ] ; fhir:variable [ fhir:v "id" ] ; fhir:condition [ fhir:v "(root != '2.16.840.1.113883.2.9.4.3.2')" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "UUID" ] ; ( fhir:source [ fhir:context [ fhir:v "id" ] ; fhir:element [ fhir:v "extension" ] ; fhir:variable [ fhir:v "ext" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "request" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "url" ] ; fhir:transform [ fhir:v "append" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Practitioner?identifier=" ] ] [ fhir:value [ fhir:v "ext" ] ] ) ] ) ] ) ] [ fhir:name [ fhir:v "meta" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "meta" ] ; fhir:variable [ fhir:v "meta" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "coding" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "meta" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "tag" ] ; fhir:variable [ fhir:v "coding" ] ; fhir:transform [ fhir:v "create" ] ; ( fhir:parameter [ fhir:value [ fhir:v "Coding" ] ] ) ] ) ; ( fhir:rule [ fhir:name [ fhir:v "system" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "system" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "http://algoritmodiscoring" ] ] ) ] ) ] [ fhir:name [ fhir:v "code" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "coding" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "code" ] ; fhir:transform [ fhir:v "copy" ] ; ( fhir:parameter [ fhir:value [ fhir:v "ClinicalDocument/body/TerapiaFarmacologicaConsigliata/participant" ] ] ) ] ) ] ) ] ) ] [ fhir:name [ fhir:v "addr" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "addr" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "address" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "telecom" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "telecom" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "telecom" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "partname" ] ; ( fhir:source [ fhir:context [ fhir:v "practr" ] ; fhir:element [ fhir:v "playingEntity" ] ; fhir:variable [ fhir:v "plentity" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "name" ] ; ( fhir:source [ fhir:context [ fhir:v "plentity" ] ; fhir:element [ fhir:v "name" ] ; fhir:variable [ fhir:v "vvv" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "name" ] ; fhir:variable [ fhir:v "vvv" ] ; fhir:transform [ fhir:v "create" ] ] ) ] [ fhir:name [ fhir:v "birth" ] ; ( fhir:source [ fhir:context [ fhir:v "plentity" ] ; fhir:element [ fhir:v "birthTime" ] ; fhir:variable [ fhir:v "birthTime" ] ] ) ; ( fhir:rule [ fhir:name [ fhir:v "value" ] ; ( fhir:source [ fhir:context [ fhir:v "birthTime" ] ; fhir:element [ fhir:v "value" ] ; fhir:variable [ fhir:v "date" ] ] ) ; ( fhir:target [ fhir:context [ fhir:v "practitioner1" ] ; fhir:contextType [ fhir:v "variable" ] ; fhir:element [ fhir:v "birthDate" ] ; fhir:transform [ fhir:v "truncate" ] ; ( fhir:parameter [ fhir:value [ fhir:v "date" ] ] [ fhir:value [ fhir:v "10"^^xsd:integer ] ] ) ] ) ] ) ] ) ] ) ] ) ] ) ] ) . #
IG © 2023+ HL7 Italy. Package hl7.fhir.it.cda2fhir#0.1.0 based on FHIR 4.0.1. Generated 2024-09-15
Links: Table of Contents |
QA Report