CDA to FHIR Maps
0.1.0 - ci-build Italy flag

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

: CDA to FHIR - PSS - TTL Representation

Draft as of 2026-10-20

Raw ttl | Download

@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 -------------------------------------------------------------------

<http://hl7.org/fhir/StructureMap/cda2fhirPs> a fhir:StructureMap ;
  fhir:nodeRole fhir:treeRoot ;
  fhir:Resource.id [ fhir:value "cda2fhirPs"] ;
  fhir:DomainResource.text [
     fhir:Narrative.status [ fhir:value "generated" ] ;
     fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n         <pre>map \"http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirPs\" = \"cda2fhirPs\"\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 -&gt;  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 -&gt; patient.identifier as identifier then {\n          id.root as r -&gt; identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n          id.extension as ext1 -&gt; identifier.value = ext1 \"value\";\n          id.assigningAuthorityName as s -&gt;  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 -&gt; requestPAT.url = append('Patient?identifier=', ext) \"UUID\";\n        } \"ext\";\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 -&gt; encounter.status = 'finished' \"finished\";\n  cda -&gt; encounter.class = create('Coding') as coding then {\n    cda -&gt; coding.code = 'summary' \"code\";\n  } \"coding\";\n  cda -&gt; bundle.id = uuid() \"id\";\n  cda.id -&gt; bundle.identifier \"identifier\";\n  cda -&gt; bundle.type = 'transaction' \"type\";\n  // cda.effectiveTime -&gt; bundle.timestamp;\n  cda -&gt; bundle.timestamp = (timestamp.now()) \"date\";\n  cda then ClinicalDocumentComposition(cda, composition, patient, encounter, bundle, DocumentReference) \"composition\";\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 -&gt; composition.section as tgtSection then ClinicalDocumentSection(cda, srcSection, patient, tgtSection, bundle, encounter, composition);\n        };\n      };\n    } \"body\";\n  } \"diagnostic\";\n}\n\ngroup ClinicalDocumentSection(source cda : ClinicalDocument, source src : Section, target patient : Patient, target tgt, target bundle : Bundle, target enc : Encounter, target composition : Composition) {\n  src.title as t -&gt; tgt.title = (t.dataString);\n  src.code -&gt; tgt.code;\n  src.entry as entry then {\n    src.text as cdaText -&gt; tgt.text as fhirText then {\n      cdaText -&gt; fhirText.status = 'generated' \"narrativeStatus\";\n      cdaText as t -&gt; fhirText.div = t \"narrativeText\";\n    } \"cdaText\";\n    // sezioni che sono strutturate\n    src.code where (code = '30954-2') then {\n      entry.organizer as organizer -&gt;  bundle.entry as e0,  e0.request = create('BackboneElement') as request,  request.method = 'POST',  e0.resource = create('DiagnosticReport') as dia,  dia.id = uuid() as uuid0,  e0.fullUrl = append('https://example/DiagnosticReport/', uuid0),  request.url = 'DiagnosticReport',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/DiagnosticReport/' + %dia.id) then DiagnosticReportFunction(organizer, patient, enc, dia, bundle) \"diagnostic\";\n    } \"entryObs\";\n    src.code where (code = '29762-2') or (code = '10162-6') then {\n      entry.observation as observation -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, enc, obs1, bundle) \"obs1\";\n    } \"entryObs\";\n    src.code where (code = '8716-3') or (code = '47420-5') then {\n      entry.organizer as organizer -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs2.id) then ObservationOrganizer(src, organizer, patient, enc, obs2, bundle) \"obs2\";\n      entry.observation as organizer -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs2.id) then ObservationOrganizer(src, organizer, patient, enc, obs2, bundle) \"obs2\";\n    } \"organizer\";\n    src.code where code = '11450-4' then {\n      entry.act as act -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Condition/' + %condition.id) then ConditionFunction(act, condition, patient, enc, bundle) \"condition\";\n    } \"listaDeiProblemi\";\n    src.code where (code = '48765-2') then {\n      entry.act as act -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/AllergyIntolerance/' + %allergy.id) then allergyFunction(act, allergy, patient, enc) \"allergy\";\n    } \"entryAct\";\n    src.code where code = '10160-0' then {\n      entry.substanceAdministration as subAdmin -&gt;  bundle.entry as e6,  e6.request = create('BackboneElement') as request,  request.method = 'POST',  e6.resource = create('MedicationStatement') as medicationstatement,  medicationstatement.id = uuid() as uuid6,  e6.fullUrl = append('https://example/MedicationStatement/', uuid6),  request.url = 'MedicationStatement',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/MedicationStatement/' + %medicationstatement.id) then MedicationStatement(subAdmin, medicationstatement, patient, enc, bundle) \"TerapiaFarmacologica\";\n    } \"terapia\";\n    src.code where code = '11369-6' then {\n      entry.substanceAdministration as subVACC -&gt;  bundle.entry as e7,  e7.request = create('BackboneElement') as request,  request.method = 'POST',  e7.resource = create('Immunization') as immunization,  immunization.id = uuid() as uuid7,  e7.fullUrl = append('https://example/Immunization/', uuid7),  request.url = 'Immunization',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Immunization/' + %immunization.id) then Immunization(subVACC, patient, enc, immunization, bundle) \"immunization\";\n    } \"vacc\";\n    src.code where code = '10157-6' then {\n      entry.organizer as organizer -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/FamilyMemberHistory/' + %familyMember.id) then FamilyMemberFunction(organizer, familyMember, patient) \"family\";\n    } \"family\";\n    src.code where code = '46264-8' then {\n      entry.supply as supply -&gt;  bundle.entry as e8,  e8.request = create('BackboneElement') as request,  request.method = 'POST',  e8.resource = create('Procedure') as procedure,  procedure.id = uuid() as uuid8,  e8.fullUrl = append('https://example/Procedure/', uuid8),  request.url = 'Procedure',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Procedure/' + %procedure.id) then Procedure(supply, patient, enc, procedure, bundle) \"protesi\";\n    } \"impianti\";\n    src.code where code = '47519-4' then {\n      entry.procedure as procedure -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Procedure/' + %procedure2.id) then Procedure(procedure, patient, enc, procedure2, bundle) \"tratt\";\n    } \"trattamentiProcedure\";\n    src.code where code = '46240-8' then {\n      // entry.encounter as encounter -&gt; enc then{\n      entry.encounter as encounter -&gt;  bundle.entry as e9,  e9.request = create('BackboneElement') as request,  request.method = 'POST',  e9.resource = create('Encounter') as encounterF,  encounterF.id = uuid() as uuid9,  e9.fullUrl = append('https://example/Encounter/', uuid9),  request.url = 'Encounter',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounterF.id) then EncounterFunction(encounter, patient, enc, encounterF, bundle);\n    } \"visiteRicoveri\";\n    src.code where code = '57827-8' then {\n      entry.act as act -&gt;  bundle.entry as e13,  e13.request = create('BackboneElement') as request,  request.method = 'POST',  e13.resource = create('Coverage') as coverage,  coverage.id = uuid() as uuid13,  e13.fullUrl = append('https://example/Coverage/', uuid13),  request.url = 'Coverage',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Coverage/' + %coverage.id) then Coverage(act, patient, enc, coverage, bundle) \"esen\";\n    } \"esenzioni\";\n    src.code where code = 'PSSIT99' then {\n      entry.act as act -&gt;  bundle.entry as e14,  e14.request = create('BackboneElement') as request,  request.method = 'POST',  e14.resource = create('OrganizationAffiliation') as affiliation,  affiliation.id = uuid() as uuid14,  e14.fullUrl = append('https://example/OrganizationAffiliation/', uuid14),  request.url = 'OrganizationAffiliation',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/OrganizationAffiliation/' + %affiliation.id) then OrganizationAffiliation(act, patient, enc, affiliation, bundle) \"OrgAffiliation\";\n    } \"retiPatologia\";\n  };\n  src where src.entry.exists() then {\n    src.code where code = '18776-5' then {\n      src -&gt;  bundle.entry as e11,  e11.request = create('BackboneElement') as request,  request.method = 'POST',  e11.resource = create('CarePlan') as careplan,  careplan.id = uuid() as uuid11,  e11.fullUrl = append('https://example/CarePlan/', uuid11),  request.url = 'CarePlan',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/CarePlan/' + %careplan.id) then {\n        src.entry as entry then CarePlanFunction(entry, careplan, patient, enc, bundle) \"prestazioni\";\n      } \"pianiCura\";\n    } \"raccoglitore\";\n  } \"esiste\";\n  src where src.entry.exists().not() then {\n    // Anmanesi Familiare narrativa\n    src.code where code = '10157-6' then {\n      src.text as text -&gt;  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',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/FamilyMemberHistory/' + %familyMember.id) then {\n        src -&gt;  familyMember.patient = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n        src -&gt; familyMember.status = 'health-unknown' \"statusS\";\n        text -&gt; familyMember.note as note then {\n          text as t -&gt; note.text = t \"reference\";\n        } \"reference\";\n        text -&gt; familyMember.relationship = create('CodeableConcept') as relation then {\n          text as txt -&gt; relation.text = txt \"text\";\n        } \"medication\";\n      } \"family\";\n    } \"familyraccoglitore\";\n    // Piano di cura narrativa\n    src.code where code = '18776-5' then {\n      src.text as text -&gt;  bundle.entry as e11,  e11.request = create('BackboneElement') as request,  request.method = 'POST',  e11.resource = create('CarePlan') as careplan,  careplan.id = uuid() as uuid11,  e11.fullUrl = append('https://example/CarePlan/', uuid11),  request.url = 'CarePlan',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/CarePlan/' + %careplan.id) then {\n        src -&gt;  careplan.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n        // src-&gt; careplan.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";\n        src -&gt; careplan.status = 'active' \"status\";\n        src -&gt; careplan.intent = 'order' \"intent\";\n        text -&gt; careplan.note as note then {\n          text as t -&gt; note.text = t \"reference\";\n        } \"reference\";\n      } \"pianiCura\";\n    } \"raccoglitore\";\n    // sezioni che sono narrative\n    src.code where (code = '30954-2') or (code = '29762-2') or (code = '8716-3') or (code = '47420-5') or (code = '42348-3') then {\n      src.text as text -&gt;  bundle.entry as e13,  e13.request = create('BackboneElement') as request,  request.method = 'POST',  e13.resource = create('Observation') as obs1,  obs1.id = uuid() as uuid13,  e13.fullUrl = append('https://example/Observation/', uuid13),  request.url = 'Observation',  tgt.entry = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs1.id) then {\n        src -&gt;  obs1.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n        // src -&gt; obs1.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";\n        src -&gt; obs1.status = 'preliminary' \"obsst\";\n        src.code -&gt; obs1.code \"obscde\";\n        src -&gt; obs1.status = 'final' \"statusS\";\n        text -&gt; obs1.note as note then {\n          text as t -&gt; note.text = create('string') as textNote then EDstring(t, textNote) \"note\";\n        } \"narrative\";\n      } \"txtsec\";\n    } \"narrative\";\n  } \"code\";\n  src.component as component then {\n    component.section as sec -&gt; tgt.section as tgtSection then ClinicalDocumentSection(cda, sec, patient, tgtSection, bundle, enc, dReport);\n  };\n}\n\ngroup Procedure(source src : cdaElement, target patient : Patient, target encounter : Encounter, target tgt : Procedure, target bundle : Bundle) {\n  // toASK\n  src.text as tx -&gt; tgt.note as note then {\n    tx.reference as reff -&gt; note.text = (reff.value) \"r\";\n  } \"tx\";\n  src.templateId where root = '2.16.840.1.113883.2.9.10.1.4.3.10.3' then {\n    src.effectiveTime as effectiveTime -&gt; tgt.performed = (effectiveTime.value);\n    src.code -&gt; tgt.code;\n  } \"ref\";\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; 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 -&gt; tgt.status = translate(cos, '#EventStatus', 'code') \"codeS\";\n  } \"status\";\n  src where statusCode.exists().not() -&gt; tgt.status = 'unknown' \"status2\";\n  src.templateId where root = '2.16.840.1.113883.2.9.10.1.4.3.9.1' then {\n    src -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'POST',  e1.resource = create('Device') as deviceRes,  deviceRes.id = uuid() as uuid1,  e1.fullUrl = append('https://example/Device/', uuid1),  request.url = 'Device',  tgt.usedReference = create('Reference') as reference,  reference.reference = ('https://example/Device/' + %deviceRes.id) then {\n      src -&gt;  deviceRes.patient = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n      src.code -&gt; deviceRes.type;\n    } \"device\";\n    src.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.performed = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n    src.effectiveTime as effectiveTime where (low.exists()) -&gt; tgt.performed = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  } \"presenzaProtesiImpianto\";\n  src.templateId where root = '2.16.840.1.113883.2.9.10.1.4.3.9.2' then {\n    src.code as code -&gt; tgt.note as note then {\n      code.displayName as displayName -&gt; note.text = (displayName) \"text\";\n    } \"note\";\n  } \"assenza\";\n  src.templateId where root = '2.16.840.1.113883.2.9.10.1.4.3.11.1' then {\n    src.id -&gt; tgt.identifier;\n    src.code -&gt; tgt.code;\n    src.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.performed = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n    src.effectiveTime as effectiveTime where (low.exists()) -&gt; tgt.performed = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n    src.entryRelationship as entryR then {\n      entryR.observation as observation -&gt;  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.reasonReference = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle);\n    } \"entryRelProcedure\";\n  } \"procedureTrattamenti\";\n}\n\ngroup Observation(source cda, target patient : Patient, target encounter : Encounter, target ob : Observation, target bundle : Bundle) {\n  cda -&gt;  ob.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // cda-&gt; ob.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  cda.id -&gt; ob.identifier;\n  cda.code -&gt; ob.code;\n  cda -&gt; ob.status = 'final' \"Stats\";\n  // value datatype\n  cda.value : ST as st -&gt;  ob.value = create('string'),  ob.value = (st.dataString);\n  cda.value : BL as boolean -&gt; ob.value = (boolean.value) \"boolean\";\n  cda.value : INT as int -&gt; ob.value = (int.value) \"intval\";\n  cda.value : CE as val then {\n    val -&gt; ob.value = create('CodeableConcept') as ce then {\n      val.originalText as originalText then {\n        originalText.reference as reference -&gt; ce.text = (reference.value);\n      };\n      val -&gt; ce.coding as coding then {\n        val.code as code -&gt; coding.code = cast(code, 'string');\n        val.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n        val.displayName as display -&gt; coding.display = cast(display, 'string');\n      } \"code\";\n      val.translation as translation -&gt; ce.coding as coding then {\n        translation.code as code -&gt; coding.code = cast(code, 'string');\n        translation.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n        translation.displayName as display -&gt; coding.display = cast(display, 'string');\n        translation.qualifier as qualifier then {\n          qualifier.value as value -&gt; ce.coding as coding then {\n            value.code as code -&gt; coding.code = cast(code, 'string');\n            value.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n            value.displayName as display -&gt; coding.display = cast(display, 'string');\n          };\n        };\n      };\n    } \"coding\";\n  } \"val\";\n  cda.value : CD as val then {\n    val -&gt; ob.value = create('CodeableConcept') as ce then {\n      val.originalText as originalText then {\n        originalText.reference as reference -&gt; ce.text = (reference.value);\n      };\n      val -&gt; ce.coding as coding then {\n        val.code as code -&gt; coding.code = cast(code, 'string');\n        val.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n        val.displayName as display -&gt; coding.display = cast(display, 'string');\n      } \"code\";\n      val.translation as translation -&gt; ce.coding as coding then {\n        translation.code as code -&gt; coding.code = cast(code, 'string');\n        translation.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n        translation.displayName as display -&gt; coding.display = cast(display, 'string');\n        translation.qualifier as qualifier then {\n          qualifier.value as value -&gt; ce.coding as coding then {\n            value.code as code -&gt; coding.code = cast(code, 'string');\n            value.codeSystem as system -&gt; coding.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n            value.displayName as display -&gt; coding.display = cast(display, 'string');\n          };\n        };\n      };\n    } \"coding\";\n  } \"val\";\n  cda.value : PQ as val then {\n    val -&gt; ob.value = create('Quantity') as quantity then {\n      val.value as value -&gt; quantity.value = value;\n      val.unit as unit -&gt; quantity.unit = unit;\n    } \"quantity\";\n  } \"valueQuantity\";\n  cda.effectiveTime as effectiveTime where (value.exists()) -&gt; ob.effective = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n  cda.effectiveTime as effectiveTime where (low.exists()) -&gt; ob.effective = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  cda.text as text -&gt; ob.note as note then {\n    text.reference as reference -&gt; note.text = (reference.value) \"text\";\n  } \"note\";\n  cda.statusCode as s then {\n    s.code as cos -&gt; ob.status = translate(cos, '#OBSstatus', 'code') \"codeS\";\n  } \"status\";\n  // toASK è giusto siano invertiti?\n  cda.methodCode -&gt; ob.method;\n  cda.interpretationCode -&gt; ob.interpretation;\n  cda.targetSiteCode -&gt; ob.bodySite;\n  // added\n  cda.referenceRange as refrange then {\n    refrange.observationRange as obsrange then {\n      obsrange.value as val -&gt; ob.referenceRange = create('BackboneElement') as refrangeFH then {\n        val -&gt; refrangeFH.low = create('SimpleQuantity') as lowfhir then {\n          val.low as l -&gt; lowfhir.value = (l.value) \"val\";\n          val.low as l -&gt; lowfhir.unit = (l.unit) \"val\";\n        } \"de\";\n        val -&gt; refrangeFH.high = create('SimpleQuantity') as highfhir then {\n          val.high as h -&gt; highfhir.value = (h.value) \"val\";\n          val.high as h -&gt; highfhir.unit = (h.unit) \"val\";\n        } \"de\";\n      } \"refFhir\";\n    } \"obsrange\";\n  } \"regrange\";\n}\n\ngroup ObservationOrganizer(source section : section, source cda : organizer, target patient : Patient, target encounter : Encounter, target ob : Observation, target bundle : Bundle) {\n  cda -&gt;  ob.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // cda-&gt; ob.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  cda.id -&gt; ob.identifier;\n  section.code -&gt; ob.code;\n  cda -&gt; ob.status = 'final' \"Stats\";\n  cda.effectiveTime as effectiveTime where (value.exists()) -&gt; ob.effective = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n  cda.effectiveTime as effectiveTime where (low.exists()) -&gt; ob.effective = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  cda.text as text -&gt; ob.note as note then {\n    text.reference as reference -&gt; note.text = (reference.value) \"text\";\n  } \"note\";\n  cda.statusCode as s then {\n    s.code as cos -&gt; ob.status = translate(cos, '#OBSstatus', 'code') \"codeS\";\n  } \"status\";\n  cda.component as component then {\n    component.observation as observation -&gt;  bundle.entry as ei,  ei.request = create('BackboneElement') as request,  request.method = 'POST',  ei.resource = create('Observation') as obsi,  obsi.id = uuid() as uuidi,  ei.fullUrl = append('https://example/Observation/', uuidi),  request.url = 'Observation',  ob.hasMember = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obsi.id) then Observation(observation, patient, encounter, obsi, bundle) \"hasMember\";\n  };\n}\n\ngroup Coverage(source src : act, target patient : Patient, target encounter : Encounter, target tgt : Coverage, target bundle : Bundle) {\n  src -&gt;  tgt.beneficiary = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  src -&gt;  tgt.payor = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  src.id as id -&gt; tgt.identifier as idf then {\n    id -&gt; idf.value = (id.root) \"ID\";\n  };\n  src.code -&gt; tgt.type;\n  src.statusCode as statusCode then {\n    statusCode.code as s -&gt; tgt.status = translate(s, '#FinancialStatus', 'code') \"status\";\n  } \"sc\";\n  src where statusCode.exists().not() -&gt; tgt.status = 'active' \"statusAbsent\";\n  // src.effectiveTime as effectiveTime -&gt; tgt.period as period then{\n  src.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.period = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n  src.effectiveTime as effectiveTime where (low.exists()) -&gt; tgt.period = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  src.entryRelationship as entryRelationship then {\n    entryRelationship.act as ac -&gt; tgt.class as class then {\n      ac.text as text -&gt; class.type as type then {\n        text.reference as reference -&gt; type.text = (reference.value) \"value\";\n      } \"ref\";\n      ac -&gt; class.value = 'commenti' \"note\";\n    } \"QUI\";\n  } \"entryr\";\n}\n\ngroup allergyFunction(source src : cdaElement, target tgt : AllergyIntolerance, target patient : Patient, target encounter : Encounter) {\n  src -&gt;  tgt.patient = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  src.effectiveTime as effTime then {\n    effTime.low as l -&gt; tgt.recordedDate as r then TSDateTime(l, r) \"value\";\n  } \"efftime\";\n  src.entryRelationship as entryRelationship1 then {\n    entryRelationship1.observation as observation1 then {\n      observation1.id -&gt; tgt.identifier;\n      observation1.templateId where root = '2.16.840.1.113883.2.9.10.1.4.3.1.4' -&gt; tgt.code as code then {\n        observation1 -&gt; code.coding as coding then {\n          observation1 -&gt; coding.code = 'No known allergy' \"code\";\n        } \"code\";\n        src.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.onset = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n        src.effectiveTime as effectiveTime -&gt; tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n      } \"Noallergy\";\n      observation1.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.onset = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n      observation1.effectiveTime as effectiveTime -&gt; tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n      observation1.value as code then {\n        code.code as code1 -&gt; tgt.type = translate(code1, '#AllergyTypeMap', 'code') \"type\";\n        code.code as code1 -&gt; tgt.category = translate(code1, '#AllergyCategoryMap', 'code') \"category\";\n      } \"code\";\n      // toASK qui dovrei fare un controllo sul code\n      observation1.value -&gt; tgt.code;\n      observation1.participant as participant -&gt; tgt.reaction as reaction then {\n        observation1.entryRelationship as entryRelationship2 where (typeCode = 'MFST') then {\n          entryRelationship2.observation as observation2 then {\n            observation2.value -&gt; reaction.manifestation \"manifestation\";\n            observation2.code -&gt; reaction.manifestation \"manifestation\";\n            observation2.text as tx then {\n              tx.reference as reff -&gt; reaction.description = (reff.value) \"tx\";\n            } \"tx\";\n            observation2.effectiveTime as effectiveTime then {\n              effectiveTime.low as low -&gt; reaction.onset = create('dateTime') as value then TSDateTime(low, value) \"valuePeriodLow\";\n              effectiveTime.high as high -&gt; tgt.lastOccurrence = create('dateTime') as value then TSDateTime(high, value) \"valuePeriodHigh\";\n            } \"low\";\n          } \"observ2\";\n        } \"entryR2\";\n        participant.participantRole as participantRole then {\n          participantRole.playingEntity as playingEntity then {\n            playingEntity.code -&gt; 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() -&gt; tgt.reaction as reaction then {\n          observation2.value -&gt; reaction.manifestation \"manifestation\";\n          observation2.text as tx then {\n            tx.reference as reff -&gt; reaction.description = (reff.value) \"tx\";\n          } \"tx\";\n          observation2.effectiveTime as effectiveTime then {\n            effectiveTime.low as low -&gt; 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 -&gt; tgt.criticality = translate(c, '#CricalityMap', 'code') \"value\";\n          } \"criticality\";\n        } \"observ3\";\n        entryRelationship3.act as act -&gt; tgt.note as note then {\n          act.text as text then {\n            text.reference as reference -&gt; 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 -&gt; tgt.clinicalStatus as clinicalStatus then {\n            observation4.value as value then {\n              value as valu -&gt; clinicalStatus.coding = create('Coding') as coding then {\n                valu where (code = 'LA9041-0') -&gt; coding.code = 'resolved' \"code\";\n                valu where (code = 'LA18632-2') -&gt; coding.code = 'inactive' \"code\";\n                valu where (code = 'LA16666-2') -&gt; coding.code = 'active' \"code\";\n                valu -&gt; coding.system = 'http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical' \"system\";\n                valu.displayName as display -&gt; coding.display = cast(display, 'string') \"display\";\n              } \"coding\";\n            };\n            observation4.text as tx then {\n              tx.reference as ref -&gt; clinicalStatus.text = (ref.value);\n            } \"tx\";\n          } \"clinicalStatus\";\n        } \"observ4\";\n      } \"entryR4\";\n    };\n  } \"entryrelationship\";\n}\n\ngroup MedicationStatement(source src : substanceAdministration, target tgt : MedicationStatement, target patient : Patient, target encounter : Encounter, target bundle : Bundle) {\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; tgt.context = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  src.statusCode -&gt; tgt.status \"status\";\n  src.id -&gt; tgt.identifier;\n  src.text as text -&gt; tgt.note as note then {\n    text.reference as reference -&gt; note.text = (reference.value) \"text\";\n  } \"note\";\n  src.effectiveTime as eff where (value.exists()) -&gt; tgt.effective = create('dateTime') as value then TSDateTime(eff, value) \"value1\";\n  src.effectiveTime : IVL_TS as eff -&gt; tgt.effective = create('Period') as value then IVLTSPeriod(eff, value) \"valuePeriod\";\n  src -&gt; tgt.dosage = create('Dosage') as dosage then {\n    src.effectiveTime : PIVL_TS as eff then {\n      eff -&gt; dosage.timing = create('Timing') as timing then periodTiming(eff, timing) \"cod\";\n    } \"eff\";\n    src where (src.doseQuantity.exists() or src.rateQuantity.exists() or src.routeCode.exists() or src.approachSiteCode.exists()) then {\n      src.doseQuantity as doseQuant then {\n        doseQuant.originalText as ot then {\n          ot.reference -&gt; dosage.text;\n        } \"ot\";\n        doseQuant -&gt; dosage.doseAndRate as dosageRate then {\n          doseQuant -&gt; dosageRate.dose = create('Range') as d then {\n            doseQuant -&gt; d.low = create('SimpleQuantity') as l then {\n              doseQuant.low as lo -&gt; l.value = (lo.value);\n              doseQuant.low as lo -&gt; l.unit = (lo.unit);\n            } \"low\";\n            doseQuant -&gt; d.high = create('SimpleQuantity') as h then {\n              doseQuant.high as hi -&gt; h.value = (hi.value);\n              doseQuant.high as hi -&gt; 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 -&gt; dosage.text;\n        } \"ot\";\n        rateQuantity -&gt; dosage.doseAndRate as dosageRate then {\n          rateQuantity -&gt; dosageRate.rate = create('Range') as d then {\n            rateQuantity -&gt; d.low = create('SimpleQuantity') as l then {\n              rateQuantity.low as lo -&gt; l.value = (lo.value);\n              rateQuantity.low as lo -&gt; l.unit = (lo.unit);\n            } \"low\";\n            rateQuantity -&gt; d.high = create('SimpleQuantity') as h then {\n              rateQuantity.high as hi -&gt; h.value = (hi.value);\n              rateQuantity.high as hi -&gt; h.unit = (hi.unit);\n            } \"high\";\n          } \"r\";\n        } \"dosageRate\";\n      } \"rate\";\n      src.routeCode -&gt; dosage.route \"route\";\n      src.approachSiteCode -&gt; dosage.site \"site\";\n      src.targetSiteCode -&gt; dosage.site \"site\";\n    } \"route\";\n  } \"dos\";\n  src.consumable as consumable then {\n    consumable.manufacturedProduct as manufacturedProduct -&gt;  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  };\n}\n\ngroup periodTiming(source effectiveTime : PIVL_TS, target timing : Timing) {\n  effectiveTime -&gt; timing.repeat as r then {\n    effectiveTime.period as p -&gt; r.period = (p.value);\n    effectiveTime.period as p -&gt; r.periodUnit = (p.unit);\n  } \"repeat\";\n}\n\ngroup Medication(source src : substanceAdministration, 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 -&gt; tgt.code \"CE\";\n        src.administrationUnitCode -&gt; 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' -&gt; 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 -&gt; ingredient.item = create('CodeableConcept') as value then CECodeableConcept(code, value) \"CE\";\n            } \"material\";\n          } \"product\";\n        };\n        observation.value as value -&gt; ingredient.strength as strength then {\n          value -&gt; strength.numerator as numerator then {\n            value -&gt; numerator.value = (value.value) \"valueN\";\n          } \"numerator\";\n          value -&gt; strength.denominator as denominator then {\n            value -&gt; denominator.value = 1 \"valueD\";\n          } \"denominator\";\n        } \"strenght\";\n      } \"ingredient\";\n      observation.code where displayName = 'Quantità nella Confezione' then {\n        observation.value as value -&gt; tgt.amount as amount then {\n          value -&gt; amount.numerator as numerator then {\n            value -&gt; numerator.value = (value.value) \"valueN\";\n          } \"numerator\";\n          value -&gt; amount.denominator as denominator then {\n            value -&gt; denominator.value = 1 \"valueD\";\n          } \"denominator\";\n        } \"amount\";\n      } \"quantita\";\n    } \"obs\";\n  } \"entryR\";\n}\n\ngroup Immunization(source substance : substanceAdministration, target patient : Patient, target encounter : Encounter, target tgt : Immunization, target bundle : Bundle) {\n  substance -&gt;  tgt.patient = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"patientRef\";\n  // substance -&gt; tgt.encounter  = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"encounterRef\";\n  substance.id as id -&gt; tgt.identifier as idf then {\n    id.root as r -&gt; idf.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n  };\n  substance.text as text -&gt; tgt.note as note then {\n    text.reference as reference -&gt; note.text = (reference.value) \"text\";\n  } \"note\";\n  substance.statusCode as statusc where (code = 'completed') -&gt; tgt.status = 'completed';\n  substance.statusCode as statusc where (code = 'aborted') -&gt; tgt.status = 'final';\n  substance.statusCode as statusc where (code = 'suspended') -&gt; tgt.status = 'enterer-in-error';\n  substance.statusCode as statusc where (code = 'cancelled') -&gt; tgt.status = 'not-done';\n  substance.effectiveTime as time -&gt; tgt.occurrence = create('dateTime') as value then TSDateTime(time, value) \"efftime\";\n  substance.routeCode -&gt; tgt.route;\n  substance.approachSiteCode -&gt; tgt.site;\n  substance -&gt; tgt.doseQuantity = create('SimpleQuantity') as quantity then {\n    substance.doseQuantity as q then {\n      q -&gt; quantity.value = (q.value) \"val\";\n      q -&gt; quantity.unit = (q.unit) \"uni\";\n    } \"qua\";\n  } \"q\";\n  substance.consumable as cons then {\n    cons.manufacturedProduct as manufact then {\n      manufact.manufacturedMaterial as manufactmat then {\n        manufactmat.code -&gt; tgt.vaccineCode;\n        manufactmat.lotNumberText as t -&gt; tgt.lotNumber = (t.dataString);\n      } \"manufactmat\";\n      manufact.manufacturerOrganization as manufactOrg -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'PUT',  e1.resource = create('Organization') as organization then {\n        manufactOrg.id as id -&gt; organization.identifier as identifier then {\n          id.root as r -&gt; identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n          id.extension as ext -&gt; identifier.value = ext then {\n            manufactOrg -&gt; request.url = append('Organization?identifier=', ext) \"UUID\";\n          } \"ext\";\n          id.assigningAuthorityName as s -&gt;  identifier.assigner as a,  a.display = s;\n          id.root as r then {\n            id.extension as ext -&gt;  organization.id = (r + '-' + ext) as uuid,  e1.fullUrl = append('https://example/', uuid),  tgt.manufacturer = create('Reference') as reference,  reference.reference = ('https://example/' + %organization.id) \"idasi\";\n          } \"r\";\n        } \"identifier\";\n        manufactOrg.name as n -&gt; organization.name = (n.other);\n        manufactOrg -&gt; organization.meta as meta then {\n          manufactOrg -&gt; meta.tag = create('Coding') as coding then {\n            manufactOrg -&gt; coding.system = 'http://algoritmodiscoring' \"system\";\n            manufactOrg -&gt; coding.code = 'ClinicalDocument/body/Vaccinazioni/manufacturerOrganization' \"code\";\n          } \"coding\";\n        } \"meta\";\n      } \"manufactOrg\";\n    } \"manufact\";\n  } \"cons\";\n  substance.participant as part -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'PUT',  e1.resource = create('Location') as location,  location.id = uuid() as uuid1 then {\n    part -&gt; location.meta as meta then {\n      part -&gt; meta.tag = create('Coding') as coding then {\n        part -&gt; coding.system = 'http://algoritmodiscoring' \"system\";\n        part -&gt; coding.code = 'ClinicalDocument/body/Vaccinazione/participant' \"code\";\n      } \"coding\";\n    } \"meta\";\n    part.participantRole as partRole then {\n      partRole.id as id -&gt; location.identifier as identifier then {\n        id.root as r -&gt; identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n        id.extension as ext -&gt; identifier.value = ext then {\n          partRole -&gt; request.url = append('Location?identifier=', ext) \"UUID\";\n        } \"ext\";\n        id.assigningAuthorityName as s -&gt;  identifier.assigner as a,  a.display = s;\n        id.root as r then {\n          id.extension as ext -&gt;  location.id = (r + '-' + ext) as uuid,  e1.fullUrl = append('https://example/Location', uuid),  tgt.location = create('Reference') as reference,  reference.reference = ('https://example/' + %location.id) \"idasi\";\n        } \"r\";\n      } \"identifier\";\n    } \"role\";\n  } \"part\";\n  substance.entryRelationship as entrirel1 then {\n    entrirel1.observation as obs then {\n      obs.code where (code = '30973-2') then {\n        obs -&gt; tgt.protocolApplied = create('BackboneElement') as prot then {\n          obs.value as v then {\n            v.value as int -&gt; prot.doseNumber = (int.toString());\n          };\n        } \"val\";\n      } \"codecontrol\";\n    } \"obs\";\n  } \"entrirel1\";\n  substance.entryRelationship as entrirel2 then {\n    entrirel2.observation as obs then {\n      obs.code where (code = '59781-5') then {\n        obs.value as value then {\n          value.high as h then {\n            h.value as value -&gt; tgt.expirationDate = truncate(value, 10);\n          } \"val\";\n        };\n      } \"codecontrol\";\n    } \"obs\";\n  } \"entrirel2\";\n  substance.entryRelationship as entrirel4 then {\n    entrirel4.observation as obs then {\n      obs.code where (code = '59785-6') -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'POST',  e1.resource = create('Observation') as observation,  observation.id = uuid() as uuid1,  e1.fullUrl = append('https://example/Observation/', uuid1),  request.url = 'Observation',  tgt.reasonReference = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %observation.id) then {\n        obs then Observation1(entrirel4, patient, tgt, bundle, enc, observation) \"observation\";\n      } \"codecontrol\";\n    } \"obs\";\n  } \"entrirel4\";\n  substance.entryRelationship as entrirel5 then {\n    entrirel5.observation as obs then {\n      obs.code where (code = '75321-0') or (code = '5321-0') -&gt; tgt.reaction as reaction then {\n        obs -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'POST',  e1.resource = create('Observation') as observation,  observation.id = uuid() as uuid1,  e1.fullUrl = append('https://example/Observation/', uuid1),  request.url = 'Observation',  reaction.detail = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %observation.id) then Observation(obs, patient, encounter, observation, bundle) \"observation\";\n      } \"codecontrol\";\n    } \"obs\";\n  } \"entrirel5\";\n  substance.entryRelationship as entrirel5 then {\n    entrirel5.act as act then {\n      act.text as tx -&gt; tgt.note as note then {\n        tx.reference as reference -&gt; note.text = (reference.value) \"text\";\n      } \"note\";\n    } \"obs\";\n  } \"entrirel5\";\n}\n\ngroup ConditionFunction(source src : cdaElement, target tgt : Condition, target patient : patient, target encounter : encounter, target bundle : Bundle) {\n  src.id -&gt; tgt.identifier;\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  src.statusCode as stscode -&gt; tgt.verificationStatus as verifstatus then {\n    stscode as codeS -&gt; verifstatus.coding = create('Coding') as coding then {\n      codeS.code -&gt; coding.code = 'confirmed';\n      codeS -&gt; coding.system = 'http://terminology.hl7.org/CodeSystem/condition-ver-status' \"system\";\n      codeS -&gt; coding.display = cast('Confirmed', 'string') \"display\";\n    } \"coding\";\n  } \"verifstatus\";\n  src where entryRelationship.exists().not() then {\n    src.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.onset = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n    src.effectiveTime as effectiveTime -&gt; tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  } \"onset\";\n  src.entryRelationship as entryRelationship then {\n    entryRelationship.observation as obsentry then {\n      // toASK\n      obsentry.value -&gt; tgt.code;\n      obsentry.code -&gt; tgt.category;\n      obsentry.effectiveTime as effectiveTime where (value.exists()) -&gt; tgt.onset = create('dateTime') as value then TSDateTime(effectiveTime, value) \"value1\";\n      obsentry.effectiveTime as effectiveTime -&gt; tgt.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n      obsentry.text as text -&gt; tgt.note as note then {\n        text.reference as reference -&gt; note.text = (reference.value) \"text\";\n      } \"note\";\n      obsentry.entryRelationship as entryR2 then {\n        entryR2.observation as obsentry2 then {\n          obsentry2.code where code = '89261-2' then {\n            obsentry2 -&gt;  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(obsentry2, patient, encounter, obsy, bundle) \"observation\";\n          } \"observation\";\n          obsentry2.code where code = '33999-4' then {\n            obsentry2.value as value -&gt; tgt.clinicalStatus as clinicalstatus then {\n              value as val -&gt; clinicalstatus.coding = create('Coding') as coding then {\n                val where (code = 'LA9041-0') -&gt; coding.code = 'resolved' \"code\";\n                val where (code = 'LA18632-2') -&gt; coding.code = 'inactive' \"code\";\n                val where (code = 'LA16666-2') -&gt; coding.code = 'active' \"code\";\n                val -&gt; coding.system = 'http://terminology.hl7.org/CodeSystem/condition-clinical' \"system\";\n                val.displayName as display -&gt; coding.display = cast(display, 'string') \"display\";\n              } \"coding\";\n              obsentry2.text as text then {\n                text.reference as reference -&gt; clinicalstatus.text = (reference.value) \"text\";\n              };\n            } \"clinicalstatus\";\n          } \"clinicalStatus2\";\n          obsentry2.code where code = 'SEV' then {\n            obsentry2.value -&gt; tgt.severity;\n          } \"severity\";\n        };\n        entryR2.act as act then {\n          act.text as text -&gt; tgt.note as note then {\n            text.reference as reference -&gt; note.text = (reference.value) \"text\";\n          } \"note\";\n        };\n      } \"entryR\";\n    } \"EntryRelObsevation\";\n  } \"entryR\";\n}\n\ngroup FamilyMemberFunction(source src : organizer, target tgt : FamilyMemberHistory, target patient : patient) {\n  src -&gt;  tgt.patient = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"patReference\";\n  src.id -&gt; tgt.identifier;\n  src.statusCode -&gt; tgt.status;\n  src.effectiveTime as effectiveTime -&gt; tgt.date = create('date') as value then TSDate(effectiveTime, value) \"date\";\n  src.subject as subject then {\n    subject.relatedSubject as relatedSubject then {\n      relatedSubject.code -&gt; tgt.relationship \"relationshipCode\";\n      relatedSubject.subject as subject -&gt; tgt.sex as sex then {\n        subject.administrativeGenderCode as administrativeGenderCode -&gt; sex.coding as coding then {\n          administrativeGenderCode.code as sexCode -&gt; coding.code = translate(sexCode, '#cm-v3-administrative-gender', 'code') \"gender\";\n          administrativeGenderCode -&gt; coding.system = 'http://hl7.org/fhir/administrative-gender' \"system\";\n          administrativeGenderCode.displayName as dn -&gt; coding.display = dn;\n        } \"coding\";\n      };\n    } \"relatedSub\";\n  } \"relationship\";\n  src.component as component -&gt; tgt.condition as condition then {\n    component.observation as observation then {\n      observation.code -&gt; condition.code;\n      observation.text as text -&gt; tgt.note as note then {\n        text.reference as reference -&gt; note.text = (reference.value) \"value\";\n      } \"reference\";\n      observation.statusCode -&gt; tgt.status;\n      // observation.effectiveTime as effectiveTime -&gt; condition.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n      observation.value -&gt; 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 -&gt; condition.onset = create('Age') as Age then {\n              value.value as valueAge -&gt; Age.value = valueAge \"age\";\n              value.unit as unit -&gt; Age.code = unit;\n              value.unit as unit -&gt; Age.unit = unit;\n              value -&gt; Age.system = 'http://unitsofmeasure.org' \"system\";\n            };\n          } \"insorgenza\";\n          obs where (code.code = '39016-1') then {\n            obs.value as value -&gt; tgt.deceased = create('Age') as Age then {\n              value.value as valueAge -&gt; Age.value = valueAge \"age\";\n              value.unit as unit -&gt; Age.code = unit;\n              value.unit as unit -&gt; Age.unit = unit;\n              value -&gt; Age.system = 'http://unitsofmeasure.org' \"system\";\n            };\n          } \"death\";\n        } \"obser\";\n      } \"EntryRel\";\n    };\n  };\n}\n\ngroup Practitioner(source src : performer, target tgt : Encounter, target bundle : Bundle) {\n  src -&gt;  bundle.entry as e22,  e22.request = create('BackboneElement') as request,  request.method = 'PUT',  e22.resource = create('Practitioner') as practitioner1 then {\n    src.assignedEntity as assignedEntity -&gt; tgt.participant as participant then {\n      src.time as time where (value.exists()) -&gt; participant.period = create('dateTime') as value then TSDateTime(time, value) \"value1\";\n      src.time as time where (low.exists()) -&gt; participant.period = create('Period') as value then IVLTSPeriod(time, value) \"valuePeriod\";\n      // src.time as time -&gt; participant.period as period then{\n      assignedEntity.id as id -&gt; practitioner1.identifier as identifier then {\n        id.root as r -&gt; identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n        id.extension as ext -&gt; identifier.value = ext \"ext\";\n        id.assigningAuthorityName as s -&gt;  identifier.assigner as a,  a.display = s;\n        id.root as r then {\n          id.extension as ext -&gt;  practitioner1.id = (r + '-' + ext) as uuid22,  e22.fullUrl = append('https://example/Practitioner/', uuid22),  participant.individual = create('Reference') as reference,  reference.reference = ('https://example/Practitioner/' + %practitioner1.id) \"id\";\n        } \"r\";\n      } \"identifier\";\n      assignedEntity.id as id where (root = '2.16.840.1.113883.2.9.4.3.2') then {\n        id.extension as ext -&gt; request.url = append('Practitioner?identifier=', ext) \"UUID\";\n      } \"2\";\n      assignedEntity.id as id where (root != '2.16.840.1.113883.2.9.4.3.2') then {\n        id.extension as ext -&gt; request.url = append('Practitioner?identifier=', ext) \"UUID\";\n      } \"diverso\";\n      assignedEntity -&gt; practitioner1.meta as meta then {\n        src -&gt; meta.tag = create('Coding') as coding then {\n          src -&gt; coding.system = 'http://algoritmodiscoring' \"system\";\n          src -&gt; coding.code = 'ClinicalDocument/body/VisiteRicoveri/performer/' \"code\";\n        } \"coding\";\n      } \"meta\";\n      assignedEntity.addr -&gt; practitioner1.address;\n      assignedEntity.telecom -&gt; practitioner1.telecom;\n      assignedEntity.assignedPerson as person then {\n        person.name -&gt; practitioner1.name;\n        person.birthTime -&gt; practitioner1.birthDate;\n      } \"partname\";\n    } \"participant\";\n  } \"resurceCreation\";\n}\n\ngroup CarePlanFunction(source src : entry, target tgt : CarePlan, target patient : Patient, target encounter : Encounter, target bundle : Bundle) {\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  src -&gt; tgt.status = 'unknown' \"status\";\n  src -&gt; tgt.intent = 'plan' \"intent\";\n  src -&gt; tgt.activity as activity then {\n    src -&gt; activity.detail as detail then {\n      src.observation as observation then {\n        observation then {\n          observation -&gt; detail.status = 'unknown' \"status\";\n          observation -&gt;  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',  detail.reasonReference = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obs1.id) then Observation(observation, patient, encounter, obs1, bundle) \"obs1\";\n        } \"activity\";\n      } \"entryObs\";\n      src.substanceAdministration as substanceAdministration -&gt; tgt.activity as activity then {\n        substanceAdministration -&gt;  bundle.entry as e2,  e2.request = create('BackboneElement') as request,  request.method = 'POST',  e2.resource = create('MedicationRequest') as medre1,  medre1.id = uuid() as uuid2,  e2.fullUrl = append('https://example/MedicationRequest/', uuid2),  request.url = 'MedicationRequest',  activity.reference = create('Reference') as reference,  reference.reference = ('https://example/MedicationRequest/' + %medre1.id) then MedicationRequest(substanceAdministration, patient, encounter, medre1, bundle) \"Terapie\";\n      } \"entrySub\";\n      src.procedure as procedureC -&gt;  bundle.entry as e8,  e8.request = create('BackboneElement') as request,  request.method = 'POST',  e8.resource = create('Procedure') as procedure,  procedure.id = uuid() as uuid8,  e8.fullUrl = append('https://example/Procedure/', uuid8),  request.url = 'Procedure',  activity.outcomeReference = create('Reference') as reference,  reference.reference = ('https://example/Procedure/' + %procedure.id) then Procedure(procedureC, patient, encounter, procedure, bundle) \"proc\";\n      src.encounter as encounterCDA -&gt;  bundle.entry as e3,  e3.request = create('BackboneElement') as request,  request.method = 'POST',  e3.resource = create('Encounter') as encounterFHIR,  encounterFHIR.id = uuid() as uuid3,  e3.fullUrl = append('https://example/Encounter/', uuid3),  request.url = 'Encounter',  tgt.encounter = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounterFHIR.id) then {\n        // encounterCDA -&gt; encounterFHIR.partOf = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"encounterHeader\";\n        encounterCDA -&gt;  encounterFHIR.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"refPatient\";\n        encounterCDA.id -&gt; encounterFHIR.identifier;\n        encounterCDA.statusCode -&gt; encounterFHIR.status;\n        encounterCDA where statusCode.exists().not() -&gt; encounterFHIR.status = 'unknown' \"status\";\n        encounterCDA.code as code -&gt; encounterFHIR.class as class then {\n          code.code as code -&gt; class.code = cast(code, 'string');\n          code.codeSystem as system -&gt; class.system = translate(system, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri');\n          code.displayName as display -&gt; class.display = cast(display, 'string');\n        } \"class\";\n        encounterCDA.text as text -&gt; encounterFHIR.type as type then {\n          text.reference as reference -&gt; type.text = (reference.value) \"value\";\n        };\n        encounterCDA.effectiveTime as effectiveTime -&gt; encounterFHIR.period = create('Period') as period then {\n          effectiveTime -&gt; period.start = create('dateTime') as start then TSDateTime(effectiveTime, start) \"val\";\n        } \"efft\";\n      } \"viste\";\n      src.act as act then {\n        act.id -&gt; tgt.identifier;\n        act.code -&gt; activity.outcomeCodeableConcept;\n        act.text as text -&gt; activity.progress = create('Annotation') as progress then {\n          text.reference as reference -&gt; progress.text = (reference.value) \"value\";\n        };\n        act.effectiveTime as effectiveTime -&gt; detail.scheduled = create('Period') as period then {\n          effectiveTime -&gt; period.start = create('dateTime') as start then TSDateTime(effectiveTime, start) \"val\";\n        } \"efft\";\n        act -&gt; detail.status = 'completed' \"status\";\n      };\n    } \"detail\";\n  } \"activityIni\";\n}\n\ngroup MedicationRequest(source src : substanceAdministration, target patient : Patient, target encounter : Encounter, target tgt : MedicationRequest, target bundle : Bundle) {\n  // default  + mandatory\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; tgt.encounter = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";\n  src -&gt; tgt.intent = 'order' \"intent\";\n  src where statusCode.exists().not() -&gt; tgt.status = 'unknown' \"st\";\n  src.statusCode as sc then {\n    sc.code as cos -&gt; tgt.status = translate(cos, '#MedicationStatusMap', 'code') \"codeS\";\n  } \"status\";\n  src.id -&gt; tgt.identifier;\n  src.text as txt -&gt; tgt.note as note then {\n    txt.reference as reference -&gt; note.text = (reference.value) \"text\";\n  } \"note\";\n  src.effectiveTime : IVL_TS as eff -&gt; tgt.dosageInstruction = create('Dosage') as dosage then {\n    eff -&gt; dosage.timing = create('Timing') as timing then {\n      eff -&gt; timing.repeat as rep then {\n        eff -&gt; rep.bounds = create('Period') as value then IVLTSPeriod(eff, value) \"valuePeriod\";\n      } \"rep\";\n    } \"timing\";\n  } \"period\";\n  src.effectiveTime : EIVL_TS as effe -&gt; tgt.dosageInstruction = create('Dosage') as dosage then {\n    effe -&gt; dosage.timing = create('Timing') as timing then {\n      effe -&gt; timing.repeat as rep then {\n        effe.eventCode as ev -&gt; rep.when = (ev.code);\n      } \"rep\";\n    } \"timing\";\n  } \"period\";\n  src.effectiveTime : IVL_TS as eff -&gt;  tgt.dosageInstruction = create('Dosage') as dosage,  dosage.timing = create('Timing') as timing,  timing.event = (eff.value) \"tim\";\n  src.effectiveTime : PIVL_TS as eff -&gt; tgt.dosageInstruction = create('Dosage') as dosage then {\n    eff -&gt; 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 -&gt; tgt.dosageInstruction = create('Dosage') as dosageInstruction then {\n      src.doseQuantity as doseQuant then {\n        doseQuant.originalText as ot then {\n          ot.reference -&gt; dosageInstruction.text;\n        } \"ot\";\n        doseQuant -&gt; dosageInstruction.doseAndRate as dosageRate then {\n          doseQuant -&gt; dosageRate.dose = create('Range') as d then {\n            doseQuant -&gt; d.low = create('SimpleQuantity') as l then {\n              doseQuant.low as lo -&gt; l.value = (lo.value);\n              doseQuant.low as lo -&gt; l.unit = (lo.unit);\n            } \"low\";\n            doseQuant -&gt; d.high = create('SimpleQuantity') as h then {\n              doseQuant.high as hi -&gt; h.value = (hi.value);\n              doseQuant.high as hi -&gt; 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 -&gt; dosageInstruction.text;\n        } \"ot\";\n        rateQuantity -&gt; dosageInstruction.doseAndRate as dosageRate then {\n          rateQuantity -&gt; dosageRate.rate = create('Range') as d then {\n            rateQuantity -&gt; d.low = create('SimpleQuantity') as l then {\n              rateQuantity.low as lo -&gt; l.value = (lo.value);\n              rateQuantity.low as lo -&gt; l.unit = (lo.unit);\n            } \"low\";\n            rateQuantity -&gt; d.high = create('SimpleQuantity') as h then {\n              rateQuantity.high as hi -&gt; h.value = (hi.value);\n              rateQuantity.high as hi -&gt; h.unit = (hi.unit);\n            } \"high\";\n          } \"r\";\n        } \"dosageRate\";\n      } \"rate\";\n      src.routeCode -&gt; dosageInstruction.route \"route\";\n      src.approachSiteCode -&gt; dosageInstruction.site \"site\";\n      src.targetSiteCode -&gt; dosageInstruction.site \"site\";\n    } \"dosageIn\";\n  } \"condition\";\n  src.consumable as consumable -&gt;  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 -&gt; tgt.dispenseRequest as dispenseRequest then {\n      supply.quantity as quantityCDA -&gt; dispenseRequest.quantity as quantityFHIR then {\n        quantityCDA -&gt; 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 -&gt; tgt.authoredOn \"autor\";\n  } \"Partecipant\";\n}\n\ngroup OrganizationAffiliation(source src : act, target patient : Patient, target enc : Encounter, target tgt : OrganizationAffiliation, target bundle : Bundle) {\n  src.id -&gt; tgt.identifier;\n  // src.code -&gt; tgt.specialty as specialty then{\n  src.statusCode where code = 'active' -&gt; tgt.active = true;\n  src.statusCode where (code = 'active').not() -&gt; tgt.active = false;\n  src.effectiveTime as eff -&gt; tgt.period;\n  // src.code -&gt; tgt.specialty;\n  src -&gt; tgt.specialty = create('CodeableConcept') as spec then {\n    src.code as code then {\n      code -&gt; spec.coding = create('Coding') as cd then {\n        code -&gt; cd.code = (code.code) \"code\";\n        code -&gt; cd.display = (code.displayName) \"code\";\n        code.codeSystem as r -&gt; cd.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n      } \"cd\";\n    } \"spec\";\n    src.entryRelationship as entry then {\n      entry.act as a then {\n        a.text as tx then {\n          tx.reference as reff -&gt; spec.text = (reff.value);\n        } \"ref\";\n      };\n    } \"entry\";\n  } \"a\";\n}\n\ngroup DiagnosticReportFunction(source src : organizer, target patient : Patient, target enc : Encounter, target tgt : DiagnosticReport, target bundle : Bundle) {\n  src -&gt;  tgt.subject = create('Reference') as reference,  reference.reference = ('https://example/Patient/' + %patient.id) \"reference\";\n  // src -&gt; tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";\n  src.code -&gt; tgt.code;\n  src.statusCode where code = 'completed' -&gt; tgt.status = 'final';\n  src.effectiveTime as eff where (value.exists()) -&gt; tgt.effective = create('dateTime') as value then TSDateTime(eff, value) \"value1\";\n  src.effectiveTime as eff where (low.exists()) -&gt; tgt.effective = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";\n  src.component as component then {\n    component.observation as observation -&gt;  bundle.entry as ei,  ei.request = create('BackboneElement') as request,  request.method = 'POST',  ei.resource = create('Observation') as obsi,  obsi.id = uuid() as uuidi,  ei.fullUrl = append('https://example/Observation/', uuidi),  request.url = 'Observation',  tgt.result = create('Reference') as reference,  reference.reference = ('https://example/Observation/' + %obsi.id) then Observation(observation, patient, enc, obsi, bundle) \"hasMember\";\n  };\n}\n\ngroup EncounterFunction(source src : cdaElement, target patient : Patient, target encounter : Encounter, target tgt : Encounter, target bundle : Bundle) {\n  src.id -&gt; tgt.identifier;\n  src.statusCode -&gt; tgt.status;\n  src where statusCode.exists().not() -&gt; tgt.status = 'unknown' \"status\";\n  src.code as code -&gt; tgt.class as class then {\n    code -&gt; class.code = (code.code) \"code\";\n    code -&gt; class.display = (code.displayName) \"display\";\n    code.codeSystem as r -&gt; class.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n  } \"co\";\n  // src.effectiveTime as effective -&gt; tgt.period as period then{\n  src where effectiveTime.low.exists() or effectiveTime.high.exists() then {\n    src.effectiveTime as eff -&gt; tgt.period = create('Period') as period then IVLTSPeriod(eff, period);\n  } \"where\";\n  // effectiveTime = time-stamp\n  src where effectiveTime.low.exists().not() or effectiveTime.high.exists().not() then {\n    src.effectiveTime as effectivetime1 -&gt; tgt.period = create('Period') as period then {\n      effectivetime1 -&gt; period.start = create('dateTime') as start then TSDateTime(effectivetime1, start) \"val\";\n    } \"efft\";\n  } \"where\";\n  // src.effectiveTime as eff where (value.exists()) -&gt; tgt.period = create('dateTime') as value then TSDateTime(eff, value) \"value1\";\n  src.text as tx -&gt; tgt.type as ty then {\n    tx.reference as reff -&gt; ty.text = (reff.value) \"textType\";\n  };\n  src.performer as performer -&gt; tgt.participant as part then {\n    performer -&gt; part.period as period then {\n      performer.time as time -&gt; period.start as start then TSDateTime(time, start) \"val\";\n    } \"period\";\n    performer.assignedEntity as assentity -&gt;  bundle.entry as e1,  e1.request = create('BackboneElement') as request,  request.method = 'POST',  e1.resource = create('PractitionerRole') as practitionerRole,  practitionerRole.id = uuid() as uuid1,  e1.fullUrl = append('https://example/PractitionerRole/', uuid1),  request.url = 'PractitionerRole',  tgt.participant = create('BackboneElement') as participant1,  participant1.individual = create('Reference') as referencepart,  referencepart.reference = ('https://example/PractitionerRole/' + %practitionerRole.id) then {\n      assentity.code -&gt; practitionerRole.code;\n      assentity -&gt;  bundle.entry as e2,  e2.request = create('BackboneElement') as request,  request.method = 'PUT',  e2.resource = create('Practitioner') as practitioner then {\n        assentity -&gt; practitioner.meta as meta then {\n          assentity -&gt; meta.tag = create('Coding') as coding then {\n            assentity -&gt; coding.system = 'http://algoritmodiscoring' \"system\";\n            assentity -&gt; coding.code = 'ClinicalDocument/body/encounter/performer' \"code\";\n          } \"coding\";\n        } \"meta\";\n        assentity.id as id -&gt; practitioner.identifier as identifier then {\n          id.root as r -&gt; identifier.system = translate(r, 'http://hl7.org/fhir/ConceptMap/special-oid2uri', 'uri') \"root1\";\n          id.extension as ext -&gt; identifier.value = ext then {\n            assentity -&gt; request.url = append('Practitioner?identifier=', ext) \"UUID\";\n          } \"ext\";\n          id.assigningAuthorityName as s -&gt;  identifier.assigner as a,  a.display = s;\n          id.root as r then {\n            id.extension as ext -&gt;  practitioner.id = (r + '-' + ext) as uuid2,  e2.fullUrl = append('https://example/Practitioner/', uuid2),  practitionerRole.practitioner = create('Reference') as reference,  reference.reference = ('https://example/Practitioner/' + %practitioner.id) \"performer\";\n          } \"r\";\n        } \"identifier\";\n        assentity.id as id where (root = '2.16.840.1.113883.2.9.4.3.2') then {\n          id.extension as ext -&gt; request.url = append('Practitioner?identifier=', ext) \"UUID\";\n        } \"2\";\n        assentity.id as id where (root != '2.16.840.1.113883.2.9.4.3.2') then {\n          id.extension as ext -&gt; request.url = append('Practitioner?identifier=', ext) \"UUID\";\n        } \"2\";\n        assentity.addr -&gt; practitioner.address;\n        assentity.telecom -&gt; practitioner.telecom;\n        assentity.assignedPerson as person then {\n          person.name -&gt; practitioner.name;\n          person.birthTime as birthTime then {\n            birthTime.value as date -&gt; practitioner.birthDate = truncate(date, 10);\n          } \"birth\";\n        } \"name\";\n      } \"assignedEntity\";\n    } \"performer\";\n  } \"01\";\n}\n\n</pre>\n      </div>"
  ] ;
  fhir:StructureMap.url [ fhir:value "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirPs"] ;
  fhir:StructureMap.version [ fhir:value "0.1.0"] ;
  fhir:StructureMap.name [ fhir:value "cda2fhirPs"] ;
  fhir:StructureMap.status [ fhir:value "draft"] ;
  fhir:StructureMap.date [ fhir:value "2026-10-20T14:46:29+00:00"^^xsd:dateTime] ;
  fhir:StructureMap.publisher [ fhir:value "HL7 Italy"] ;
  fhir:StructureMap.contact [
     fhir:index 0 ;
     fhir:ContactDetail.name [ fhir:value "HL7 Italy" ] ;
     fhir:ContactDetail.telecom [
       fhir:index 0 ;
       fhir:ContactPoint.system [ fhir:value "url" ] ;
       fhir:ContactPoint.value [ fhir:value "http://hl7.it" ]
     ]
  ] ;
  fhir:StructureMap.jurisdiction [
     fhir:index 0 ;
     fhir:CodeableConcept.coding [
       fhir:index 0 ;
       fhir:Coding.system [ fhir:value "urn:iso:std:iso:3166" ] ;
       fhir:Coding.code [ fhir:value "IT" ] ;
       fhir:Coding.display [ fhir:value "Italy" ]
     ]
  ] ;
  fhir:StructureMap.structure [
     fhir:index 0 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "source" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "ClinicalDocument" ]
  ], [
     fhir:index 1 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/AssignedAuthor" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssignedAuthor>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "AssignedAuthor" ]
  ], [
     fhir:index 2 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/AssignedEntity" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssignedEntity>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "AssignedEntity" ]
  ], [
     fhir:index 3 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/AssociatedEntity" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AssociatedEntity>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "AssociatedEntity" ]
  ], [
     fhir:index 4 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/CustodianOrganization" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/CustodianOrganization>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "CustodianOrganization" ]
  ], [
     fhir:index 5 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/OrganizationPartOf" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/OrganizationPartOf>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "OrganizationPartOf" ]
  ], [
     fhir:index 6 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/Organization" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Organization>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "rapresentedOrganization" ]
  ], [
     fhir:index 7 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/Section" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Section>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Section" ]
  ], [
     fhir:index 8 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/PatientRole" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/PatientRole>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "queried" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "PatientRole" ]
  ], [
     fhir:index 9 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/AD" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/AD>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "source" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "AD" ]
  ], [
     fhir:index 10 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Bundle" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Bundle>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "target" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Bundle" ]
  ], [
     fhir:index 11 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Composition" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Composition>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Composition" ]
  ], [
     fhir:index 12 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Patient" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Patient>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Patient" ]
  ], [
     fhir:index 13 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Encounter" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Encounter>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Encounter" ]
  ], [
     fhir:index 14 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Person" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Person>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Patient" ]
  ], [
     fhir:index 15 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/List" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/List>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "List" ]
  ], [
     fhir:index 16 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Practitioner" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Practitioner>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Practitioner" ]
  ], [
     fhir:index 17 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/Organization" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/Organization>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Organization" ]
  ], [
     fhir:index 18 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/Act" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/Act>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "produced" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "Act" ]
  ], [
     fhir:index 19 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/IVL-PQ" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/IVL-PQ>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "source" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "IVL_PQ" ]
  ], [
     fhir:index 20 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/cda/StructureDefinition/PQ" ;
       fhir:link <http://hl7.org/fhir/cda/StructureDefinition/PQ>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "source" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "PQ" ]
  ], [
     fhir:index 21 ;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/SimpleQuantity" ;
       fhir:link <http://hl7.org/fhir/StructureDefinition/SimpleQuantity>
     ] ;
     fhir:StructureMap.structure.mode [ fhir:value "target" ] ;
     fhir:StructureMap.structure.alias [ fhir:value "SimpleQuantity" ]
  ] ;
  fhir:StructureMap.import [
     fhir:value "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirDataTypes" ;
     fhir:index 0 ;
     fhir:link <http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirDataTypes>
  ], [
     fhir:value "http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirHeader" ;
     fhir:index 1 ;
     fhir:link <http://hl7.it/fhir/cda2fhir/StructureMap/cda2fhirHeader>
  ] ;
  fhir:StructureMap.group [
     fhir:index 0 ;
     fhir:StructureMap.group.name [ fhir:value "CdaToBundle" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "cda" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "ClinicalDocument" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "ClinicalDocumentToBody" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e" ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "composition" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Composition" ]
         ]
       ], [
         fhir:index 4 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "composition" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ], [
         fhir:index 5 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Composition/" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
         ]
       ], [
         fhir:index 6 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Composition" ]
         ]
       ], [
         fhir:index 7 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e2" ]
       ], [
         fhir:index 8 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "requestPAT" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 9 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "requestPAT" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PUT" ]
         ]
       ], [
         fhir:index 10 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Patient" ]
         ]
       ], [
         fhir:index 11 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid2" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ], [
         fhir:index 12 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Patient/" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid2" ]
         ]
       ], [
         fhir:index 13 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e3" ]
       ], [
         fhir:index 14 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 15 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
         ]
       ], [
         fhir:index 16 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "encounter" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
         ]
       ], [
         fhir:index 17 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "encounter" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid3" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ], [
         fhir:index 18 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Encounter/" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid3" ]
         ]
       ], [
         fhir:index 19 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
         ]
       ], [
         fhir:index 20 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e4" ]
       ], [
         fhir:index 21 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e4" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 22 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
         ]
       ], [
         fhir:index 23 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e4" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "DocumentReference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "DocumentReference" ]
         ]
       ], [
         fhir:index 24 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "DocumentReference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid4" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ], [
         fhir:index 25 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e4" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/DocumentReference/" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid4" ]
         ]
       ], [
         fhir:index 26 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "DocumentReference" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "cdatobundle" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "ClinicalDocumentToBundle" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "cda" ;
             fhir:index 0
           ], [
             fhir:value "patient" ;
             fhir:index 1
           ], [
             fhir:value "composition" ;
             fhir:index 2
           ], [
             fhir:value "encounter" ;
             fhir:index 3
           ], [
             fhir:value "bundle" ;
             fhir:index 4
           ], [
             fhir:value "DocumentReference" ;
             fhir:index 5
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "recordTarget" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "recordTarget" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "recPat" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "recordTarget" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "patientRole" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "patient" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "idfr" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "patient" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "patient" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "identifier" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext1" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext1" ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "assigningAuthorityName" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "assigningAuthorityName" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "assigner" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "a" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "a" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ext" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "patient" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(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:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "requestPAT" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Patient?identifier=" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 1 ;
     fhir:StructureMap.group.name [ fhir:value "ClinicalDocumentToBundle" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "cda" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "ClinicalDocument" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "composition" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Composition" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.input.name [ fhir:value "DocumentReference" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "DocumentReference" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "finished" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "encounter" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "finished" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "encounter" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "class" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "summary" ]
           ]
         ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "identifier" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "type" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "transaction" ]
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "date" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "timestamp" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "timestamp.now()" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "cda.effectiveTime -> bundle.timestamp;" ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "composition" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "ClinicalDocumentComposition" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "cda" ;
           fhir:index 0
         ], [
           fhir:value "composition" ;
           fhir:index 1
         ], [
           fhir:value "patient" ;
           fhir:index 2
         ], [
           fhir:value "encounter" ;
           fhir:index 3
         ], [
           fhir:value "bundle" ;
           fhir:index 4
         ], [
           fhir:value "DocumentReference" ;
           fhir:index 5
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "diagnostic" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "body" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "structuredBody" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "body" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "body" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "section" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "section" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "srcSection" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "srcSection" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "composition" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "section" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "tgtSection" ]
               ] ;
               fhir:StructureMap.group.rule.dependent [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.dependent.name [ fhir:value "ClinicalDocumentSection" ] ;
                 fhir:StructureMap.group.rule.dependent.variable [
                   fhir:value "cda" ;
                   fhir:index 0
                 ], [
                   fhir:value "srcSection" ;
                   fhir:index 1
                 ], [
                   fhir:value "patient" ;
                   fhir:index 2
                 ], [
                   fhir:value "tgtSection" ;
                   fhir:index 3
                 ], [
                   fhir:value "bundle" ;
                   fhir:index 4
                 ], [
                   fhir:value "encounter" ;
                   fhir:index 5
                 ], [
                   fhir:value "composition" ;
                   fhir:index 6
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 2 ;
     fhir:StructureMap.group.name [ fhir:value "ClinicalDocumentSection" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "cda" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "ClinicalDocument" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Section" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.input.name [ fhir:value "enc" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.input.name [ fhir:value "composition" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Composition" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "title" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "title" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "title" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "t.dataString" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entry" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entry" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "cdaText" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "cdaText" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "fhirText" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "narrativeStatus" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "cdaText" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "fhirText" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "generated" ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "narrativeText" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "cdaText" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "fhirText" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "div" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "t" ]
             ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "entryObs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '30954-2')" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "diagnostic" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "organizer" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "organizer" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e0" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e0" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e0" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "dia" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "DiagnosticReport" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dia" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid0" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e0" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/DiagnosticReport/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid0" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "DiagnosticReport" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/DiagnosticReport/' + %dia.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "DiagnosticReportFunction" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "organizer" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "dia" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ] ;
         fhir:StructureMap.group.rule.documentation [ fhir:value "sezioni che sono strutturate" ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.name [ fhir:value "entryObs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '29762-2') or (code = '10162-6')" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "obs1" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs1.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "observation" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "obs1" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.name [ fhir:value "organizer" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '8716-3') or (code = '47420-5')" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "obs2" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "organizer" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "organizer" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e2" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "obs2" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "obs2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid2" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid2" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs2.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "ObservationOrganizer" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "src" ;
               fhir:index 0
             ], [
               fhir:value "organizer" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ], [
               fhir:value "enc" ;
               fhir:index 3
             ], [
               fhir:value "obs2" ;
               fhir:index 4
             ], [
               fhir:value "bundle" ;
               fhir:index 5
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "obs2" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "organizer" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e2" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "obs2" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "obs2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid2" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid2" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs2.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "ObservationOrganizer" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "src" ;
               fhir:index 0
             ], [
               fhir:value "organizer" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ], [
               fhir:value "enc" ;
               fhir:index 3
             ], [
               fhir:value "obs2" ;
               fhir:index 4
             ], [
               fhir:value "bundle" ;
               fhir:index 5
             ]
           ]
         ]
       ], [
         fhir:index 4 ;
         fhir:StructureMap.group.rule.name [ fhir:value "listaDeiProblemi" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '11450-4'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "condition" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e3" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "condition" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Condition" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "condition" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid3" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Condition/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid3" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Condition" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Condition/' + %condition.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "ConditionFunction" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "act" ;
               fhir:index 0
             ], [
               fhir:value "condition" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ], [
               fhir:value "enc" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 5 ;
         fhir:StructureMap.group.rule.name [ fhir:value "entryAct" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '48765-2')" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "allergy" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e5" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e5" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e5" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "allergy" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "AllergyIntolerance" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "allergy" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid5" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e5" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/AllergyIntolerance/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid5" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "AllergyIntolerance" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/AllergyIntolerance/' + %allergy.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "allergyFunction" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "act" ;
               fhir:index 0
             ], [
               fhir:value "allergy" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ], [
               fhir:value "enc" ;
               fhir:index 3
             ]
           ]
         ]
       ], [
         fhir:index 6 ;
         fhir:StructureMap.group.rule.name [ fhir:value "terapia" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '10160-0'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "TerapiaFarmacologica" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "substanceAdministration" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "subAdmin" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e6" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e6" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e6" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "medicationstatement" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "MedicationStatement" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "medicationstatement" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid6" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e6" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/MedicationStatement/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid6" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "MedicationStatement" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/MedicationStatement/' + %medicationstatement.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "MedicationStatement" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "subAdmin" ;
               fhir:index 0
             ], [
               fhir:value "medicationstatement" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ], [
               fhir:value "enc" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 7 ;
         fhir:StructureMap.group.rule.name [ fhir:value "vacc" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '11369-6'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "immunization" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "substanceAdministration" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "subVACC" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e7" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e7" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e7" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "immunization" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Immunization" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "immunization" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid7" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e7" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Immunization/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid7" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Immunization" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Immunization/' + %immunization.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Immunization" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "subVACC" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "immunization" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 8 ;
         fhir:StructureMap.group.rule.name [ fhir:value "family" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '10157-6'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "family" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "organizer" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "organizer" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e12" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "familyMember" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "FamilyMemberHistory" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid12" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/FamilyMemberHistory/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid12" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "FamilyMemberHistory" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/FamilyMemberHistory/' + %familyMember.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "FamilyMemberFunction" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "organizer" ;
               fhir:index 0
             ], [
               fhir:value "familyMember" ;
               fhir:index 1
             ], [
               fhir:value "patient" ;
               fhir:index 2
             ]
           ]
         ]
       ], [
         fhir:index 9 ;
         fhir:StructureMap.group.rule.name [ fhir:value "impianti" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '46264-8'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "protesi" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "supply" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "supply" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e8" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid8" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Procedure/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid8" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Procedure/' + %procedure.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Procedure" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "supply" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "procedure" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 10 ;
         fhir:StructureMap.group.rule.name [ fhir:value "trattamentiProcedure" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '47519-4'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "tratt" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "procedure" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e9" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "procedure2" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "procedure2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid9" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Procedure/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid9" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Procedure/' + %procedure2.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Procedure" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "procedure" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "procedure2" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 11 ;
         fhir:StructureMap.group.rule.name [ fhir:value "visiteRicoveri" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '46240-8'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "encounter" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "encounter" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "encounter" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e9" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "encounterF" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "encounterF" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid9" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e9" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Encounter/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid9" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Encounter/' + %encounterF.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "EncounterFunction" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "encounter" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "encounterF" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ] ;
           fhir:StructureMap.group.rule.documentation [ fhir:value "entry.encounter as encounter -> enc then{" ]
         ]
       ], [
         fhir:index 12 ;
         fhir:StructureMap.group.rule.name [ fhir:value "esenzioni" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '57827-8'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "esen" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e13" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coverage" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coverage" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coverage" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid13" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Coverage/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid13" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coverage" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Coverage/' + %coverage.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Coverage" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "act" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "coverage" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ], [
         fhir:index 13 ;
         fhir:StructureMap.group.rule.name [ fhir:value "retiPatologia" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = 'PSSIT99'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "OrgAffiliation" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e14" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e14" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e14" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "affiliation" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "OrganizationAffiliation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "affiliation" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid14" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e14" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/OrganizationAffiliation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid14" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "OrganizationAffiliation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/OrganizationAffiliation/' + %affiliation.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "OrganizationAffiliation" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "act" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "enc" ;
               fhir:index 2
             ], [
               fhir:value "affiliation" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "esiste" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "src.entry.exists()" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "raccoglitore" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '18776-5'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "pianiCura" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e11" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "careplan" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CarePlan" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid11" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/CarePlan/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid11" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CarePlan" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/CarePlan/' + %careplan.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "prestazioni" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "entry" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "entry" ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "CarePlanFunction" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "entry" ;
                 fhir:index 0
               ], [
                 fhir:value "careplan" ;
                 fhir:index 1
               ], [
                 fhir:value "patient" ;
                 fhir:index 2
               ], [
                 fhir:value "enc" ;
                 fhir:index 3
               ], [
                 fhir:value "bundle" ;
                 fhir:index 4
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "src.entry.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "familyraccoglitore" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '10157-6'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "family" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e12" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "familyMember" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "FamilyMemberHistory" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid12" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e12" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/FamilyMemberHistory/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid12" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "FamilyMemberHistory" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/FamilyMemberHistory/' + %familyMember.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "patient" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "statusS" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "health-unknown" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "t" ]
                 ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "medication" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "familyMember" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "relationship" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "relation" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CodeableConcept" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "txt" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "relation" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "txt" ]
                 ]
               ]
             ]
           ]
         ] ;
         fhir:StructureMap.group.rule.documentation [ fhir:value "Anmanesi Familiare narrativa" ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "raccoglitore" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '18776-5'" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "pianiCura" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e11" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "careplan" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CarePlan" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid11" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e11" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/CarePlan/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid11" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CarePlan" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/CarePlan/' + %careplan.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "active" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.documentation [ fhir:value "src-> careplan.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "intent" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "intent" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "order" ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "careplan" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "t" ]
                 ]
               ]
             ]
           ]
         ] ;
         fhir:StructureMap.group.rule.documentation [ fhir:value "Piano di cura narrativa" ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.name [ fhir:value "narrative" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '30954-2') or (code = '29762-2') or (code = '8716-3') or (code = '47420-5') or (code = '42348-3')" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "txtsec" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e13" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid13" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e13" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid13" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs1.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "obsst" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "preliminary" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.documentation [ fhir:value "src -> obs1.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "obscde" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "statusS" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "final" ]
               ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.name [ fhir:value "narrative" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "textNote" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.dependent [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.dependent.name [ fhir:value "EDstring" ] ;
                 fhir:StructureMap.group.rule.dependent.variable [
                   fhir:value "t" ;
                   fhir:index 0
                 ], [
                   fhir:value "textNote" ;
                   fhir:index 1
                 ]
               ]
             ]
           ]
         ] ;
         fhir:StructureMap.group.rule.documentation [ fhir:value "sezioni che sono narrative" ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "component" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "section" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "section" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "sec" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "section" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "tgtSection" ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "ClinicalDocumentSection" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "cda" ;
             fhir:index 0
           ], [
             fhir:value "sec" ;
             fhir:index 1
           ], [
             fhir:value "patient" ;
             fhir:index 2
           ], [
             fhir:value "tgtSection" ;
             fhir:index 3
           ], [
             fhir:value "bundle" ;
             fhir:index 4
           ], [
             fhir:value "enc" ;
             fhir:index 5
           ], [
             fhir:value "dReport" ;
             fhir:index 6
           ]
         ]
       ]
     ]
  ], [
     fhir:index 3 ;
     fhir:StructureMap.group.name [ fhir:value "Procedure" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "cdaElement" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Procedure" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reff" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reff.value" ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "toASK" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "ref" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "templateId" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "root = '2.16.840.1.113883.2.9.10.1.4.3.10.3'" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "performed" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "effectiveTime.value" ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
         ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "codeS" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "s" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "cos" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "cos" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#EventStatus" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status2" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "statusCode.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "presenzaProtesiImpianto" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "templateId" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "root = '2.16.840.1.113883.2.9.10.1.4.3.9.1'" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "device" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "deviceRes" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Device" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "deviceRes" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Device/" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Device" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "usedReference" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Device/' + %deviceRes.id" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "deviceRes" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "patient" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "deviceRes" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "performed" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "performed" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "assenza" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "templateId" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "root = '2.16.840.1.113883.2.9.10.1.4.3.9.2'" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "displayName" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "displayName" ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "procedureTrattamenti" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "templateId" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "root = '2.16.840.1.113883.2.9.10.1.4.3.11.1'" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "performed" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "performed" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ], [
         fhir:index 4 ;
         fhir:StructureMap.group.rule.name [ fhir:value "entryRelProcedure" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "entryR" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entryR" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e3" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid3" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid3" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reasonReference" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs1.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "observation" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "encounter" ;
               fhir:index 2
             ], [
               fhir:value "obs1" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 4 ;
     fhir:StructureMap.group.name [ fhir:value "Observation" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "cda" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "ob" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Observation" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "cda-> ob.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "Stats" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "final" ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "ST" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "st" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "st.dataString" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "value datatype" ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "boolean" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "BL" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "boolean" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "boolean.value" ]
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "intval" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "INT" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "int" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "int.value" ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "CE" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "val" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "ce" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CodeableConcept" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "originalText" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "originalText" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "translation" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "translation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "translation" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "qualifier" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "qualifier" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "qualifier" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "qualifier" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                   ], [
                     fhir:index 2 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                   ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 8 ;
       fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "CD" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "val" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "ce" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CodeableConcept" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "originalText" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "originalText" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "translation" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "translation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "translation" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "qualifier" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "translation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "qualifier" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "qualifier" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "qualifier" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "ce" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                   ], [
                     fhir:index 2 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                   ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 9 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valueQuantity" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "PQ" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "val" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "quantity" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "quantity" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Quantity" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "value" ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "unit" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "unit" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "unit" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "unit" ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 10 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 11 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 12 ;
       fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
           ]
         ]
       ]
     ], [
       fhir:index 13 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "codeS" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "s" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "cos" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "cos" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#OBSstatus" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
           ]
         ]
       ]
     ], [
       fhir:index 14 ;
       fhir:StructureMap.group.rule.name [ fhir:value "methodCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "methodCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "toASK è giusto siano invertiti?" ]
     ], [
       fhir:index 15 ;
       fhir:StructureMap.group.rule.name [ fhir:value "interpretationCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "interpretationCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "interpretation" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 16 ;
       fhir:StructureMap.group.rule.name [ fhir:value "targetSiteCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "targetSiteCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "bodySite" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 17 ;
       fhir:StructureMap.group.rule.name [ fhir:value "regrange" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "referenceRange" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "refrange" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obsrange" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "refrange" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observationRange" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obsrange" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "refFhir" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsrange" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "val" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "referenceRange" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "refrangeFH" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "de" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "refrangeFH" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "low" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "lowfhir" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "l" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "lowfhir" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "l.value" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "l" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "lowfhir" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "l.unit" ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "de" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "refrangeFH" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "high" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "highfhir" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "h" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "highfhir" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "h.value" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "h" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "highfhir" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "h.unit" ]
                 ]
               ]
             ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "added" ]
     ]
  ], [
     fhir:index 5 ;
     fhir:StructureMap.group.name [ fhir:value "ObservationOrganizer" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "section" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "section" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "cda" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "organizer" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "ob" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Observation" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "cda-> ob.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "section" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "Stats" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "final" ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
           ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "codeS" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "s" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "cos" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "cos" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#OBSstatus" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
           ]
         ]
       ]
     ], [
       fhir:index 8 ;
       fhir:StructureMap.group.rule.name [ fhir:value "component" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "cda" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "hasMember" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "ei" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "obsi" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "obsi" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "uuidi" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuidi" ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ob" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "hasMember" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obsi.id" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "observation" ;
             fhir:index 0
           ], [
             fhir:value "patient" ;
             fhir:index 1
           ], [
             fhir:value "encounter" ;
             fhir:index 2
           ], [
             fhir:value "obsi" ;
             fhir:index 3
           ], [
             fhir:value "bundle" ;
             fhir:index 4
           ]
         ]
       ]
     ]
  ], [
     fhir:index 6 ;
     fhir:StructureMap.group.name [ fhir:value "Coverage" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "act" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Coverage" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "beneficiary" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "payor" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "idf" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "ID" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "id" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "idf" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "id.root" ]
           ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "sc" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "statusCode" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "statusCode" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#FinancialStatus" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
           ]
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusAbsent" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "statusCode.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "active" ]
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src.effectiveTime as effectiveTime -> tgt.period as period then{" ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 8 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entryr" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "QUI" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "ac" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "class" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "class" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "ref" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "ac" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "type" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "type" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "ac" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "commenti" ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 7 ;
     fhir:StructureMap.group.name [ fhir:value "allergyFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "cdaElement" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "AllergyIntolerance" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "efftime" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effTime" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "effTime" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "l" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "recordedDate" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "r" ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "l" ;
             fhir:index 0
           ], [
             fhir:value "r" ;
             fhir:index 1
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entryrelationship" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship1" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship1" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "observation1" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "Noallergy" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "templateId" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "root = '2.16.840.1.113883.2.9.10.1.4.3.1.4'" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "code" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "No known allergy" ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "effectiveTime" ;
                 fhir:index 0
               ], [
                 fhir:value "value" ;
                 fhir:index 1
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "effectiveTime" ;
                 fhir:index 0
               ], [
                 fhir:value "value" ;
                 fhir:index 1
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "effectiveTime" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "effectiveTime" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "type" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code1" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code1" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#AllergyTypeMap" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "category" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code1" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "category" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code1" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#AllergyCategoryMap" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
               ]
             ]
           ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ] ;
           fhir:StructureMap.group.rule.documentation [ fhir:value "toASK qui dovrei fare un controllo sul code" ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.name [ fhir:value "participant" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "participant" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "participant" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reaction" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reaction" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "entryR2" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship2" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(typeCode = 'MFST')" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "observ2" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "observation2" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "manifestation" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "manifestation" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "manifestation" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "manifestation" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "reff" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "description" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reff.value" ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 3 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "valuePeriodLow" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "low" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
                     fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
                     ]
                   ] ;
                   fhir:StructureMap.group.rule.dependent [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
                     fhir:StructureMap.group.rule.dependent.variable [
                       fhir:value "low" ;
                       fhir:index 0
                     ], [
                       fhir:value "value" ;
                       fhir:index 1
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "valuePeriodHigh" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "high" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "lastOccurrence" ] ;
                     fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
                     ]
                   ] ;
                   fhir:StructureMap.group.rule.dependent [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
                     fhir:StructureMap.group.rule.dependent.variable [
                       fhir:value "high" ;
                       fhir:index 0
                     ], [
                       fhir:value "value" ;
                       fhir:index 1
                     ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "participantRole" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "participant" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "participantRole" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "participantRole" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "playingEntity" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "participantRole" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "playingEntity" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "playingEntity" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "reaction" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "playingEntity" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "substance" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entryR2" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship2" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(typeCode = 'MFST')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observ2" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship2" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "observation2" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "observation1.participant.exists().not()" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reaction" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reaction" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "manifestation" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "manifestation" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "reff" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "description" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reff.value" ]
                   ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "valuePeriodLow" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "low" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.dependent [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
                   fhir:StructureMap.group.rule.dependent.variable [
                     fhir:value "low" ;
                     fhir:index 0
                   ], [
                     fhir:value "value" ;
                     fhir:index 1
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entryR3" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship3" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(typeCode = 'SUBJ')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observ3" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship3" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "observation3" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "criticality" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation3" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "c" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "criticality" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "c" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#CricalityMap" ]
                   ], [
                     fhir:index 2 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship3" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 9 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entryR4" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation1" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship4" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(typeCode = 'REFR')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observ4" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship4" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "observation4" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "clinicalStatus" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation4" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "clinicalStatus" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "clinicalStatus" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation4" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "valu" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "clinicalStatus" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
                     fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
                     ]
                   ] ;
                   fhir:StructureMap.group.rule.rule [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "valu" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA9041-0')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "resolved" ]
                       ]
                     ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "valu" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA18632-2')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "inactive" ]
                       ]
                     ]
                   ], [
                     fhir:index 2 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "valu" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA16666-2')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "active" ]
                       ]
                     ]
                   ], [
                     fhir:index 3 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "valu" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical" ]
                       ]
                     ]
                   ], [
                     fhir:index 4 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "display" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "valu" ] ;
                       fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                       fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
                       ], [
                         fhir:index 1 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                       ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "tx" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "observation4" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "ref" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "clinicalStatus" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ref.value" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 8 ;
     fhir:StructureMap.group.name [ fhir:value "MedicationStatement" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "substanceAdministration" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "MedicationStatement" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.context = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
           ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "eff" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "IVL_TS" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "eff" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "dos" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "eff" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.type [ fhir:value "PIVL_TS" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "cod" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "eff" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "timing" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "timing" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Timing" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "periodTiming" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "eff" ;
               fhir:index 0
             ], [
               fhir:value "timing" ;
               fhir:index 1
             ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "route" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(src.doseQuantity.exists() or src.rateQuantity.exists() or src.routeCode.exists() or src.approachSiteCode.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "doseQuantity" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "doseQuantity" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "doseQuant" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ot" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ot" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "ot" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "dosageRate" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "doseAndRate" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "dosageRate" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "d" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageRate" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "dose" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "d" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Range" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "l" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.unit" ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "h" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.unit" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "rate" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "rateQuantity" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "rateQuantity" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ot" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ot" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "ot" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "dosageRate" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "doseAndRate" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "dosageRate" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageRate" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "rate" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "d" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Range" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "l" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.unit" ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "h" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.unit" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "route" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "routeCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "route" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "site" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "approachSiteCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "site" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "site" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "targetSiteCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "site" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "consumable" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "consumable" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "consumable" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "medication" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "consumable" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedProduct" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "manufacturedProduct" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "medication" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Medication" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "medication" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Medication/" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Medication" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "medication" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "medref" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "medref" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Medication/' + %medication.id" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "Medication" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "src" ;
             fhir:index 0
           ], [
             fhir:value "medication" ;
             fhir:index 1
           ], [
             fhir:value "patient" ;
             fhir:index 2
           ], [
             fhir:value "bundle" ;
             fhir:index 3
           ]
         ]
       ]
     ]
  ], [
     fhir:index 9 ;
     fhir:StructureMap.group.name [ fhir:value "periodTiming" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "effectiveTime" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "PIVL_TS" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "timing" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Timing" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "repeat" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "repeat" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "r" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "period" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "p" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "r" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "p.value" ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "period" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "p" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "r" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "periodUnit" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "p.unit" ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 10 ;
     fhir:StructureMap.group.name [ fhir:value "Medication" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "substanceAdministration" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Medication" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "consumable" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "consumable" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "consumable" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "product" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "consumable" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedProduct" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "manufacturedProduct" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "material" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "manufacturedProduct" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedMaterial" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "manufacturedMaterial" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "CE" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufacturedMaterial" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "form" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "administrationUnitCode" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "form" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entryR" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entryR" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entryR" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "ingredient" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "displayName = 'Grammatura'" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "ingredient" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ingredient" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "consumable" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "consumable" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "consumable" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "product" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "consumable" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedProduct" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "manufacturedProduct" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "material" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "manufacturedProduct" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedMaterial" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "manufacturedMaterial" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "CE" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "manufacturedMaterial" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "ingredient" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "item" ] ;
                     fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CodeableConcept" ]
                     ]
                   ] ;
                   fhir:StructureMap.group.rule.dependent [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.dependent.name [ fhir:value "CECodeableConcept" ] ;
                     fhir:StructureMap.group.rule.dependent.variable [
                       fhir:value "code" ;
                       fhir:index 0
                     ], [
                       fhir:value "value" ;
                       fhir:index 1
                     ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "strenght" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "ingredient" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "strength" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "strength" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "numerator" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "strength" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "numerator" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "numerator" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "valueN" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "numerator" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "value.value" ]
                   ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "denominator" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "strength" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "denominator" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "denominator" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "valueD" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "denominator" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueInteger [ fhir:value "1"^^xsd:integer ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "quantita" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "displayName = 'Quantità nella Confezione'" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "amount" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "amount" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "amount" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "numerator" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "amount" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "numerator" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "numerator" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "valueN" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "numerator" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "value.value" ]
                   ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "denominator" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "amount" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "denominator" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "denominator" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "valueD" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "denominator" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueInteger [ fhir:value "1"^^xsd:integer ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 11 ;
     fhir:StructureMap.group.name [ fhir:value "Immunization" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "substance" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "substanceAdministration" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Immunization" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "patientRef" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "idf" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "idf" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "substance -> tgt.encounter  = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"encounterRef\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
           ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "statusc" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'completed')" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "completed" ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "statusc" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'aborted')" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "final" ]
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "statusc" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'suspended')" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "enterer-in-error" ]
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "statusc" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'cancelled')" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "not-done" ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "efftime" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "time" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "occurrence" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "time" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 8 ;
       fhir:StructureMap.group.rule.name [ fhir:value "routeCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "routeCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "route" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 9 ;
       fhir:StructureMap.group.rule.name [ fhir:value "approachSiteCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "approachSiteCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "site" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 10 ;
       fhir:StructureMap.group.rule.name [ fhir:value "q" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "doseQuantity" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "quantity" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "qua" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "doseQuantity" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "q" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "q" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "q.value" ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "uni" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "q" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "q.unit" ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 11 ;
       fhir:StructureMap.group.rule.name [ fhir:value "cons" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "consumable" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "cons" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "manufact" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "cons" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedProduct" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "manufact" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "manufactmat" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "manufact" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturedMaterial" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "manufactmat" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufactmat" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "vaccineCode" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "lotNumberText" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufactmat" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "lotNumberText" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "t" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "lotNumber" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "t.dataString" ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "manufactOrg" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "manufact" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "manufacturerOrganization" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "manufactOrg" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PUT" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "organization" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Organization" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "identifier" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "organization" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "identifier" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "ext" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Organization?identifier=" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                   ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "assigningAuthorityName" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "assigningAuthorityName" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "assigner" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "a" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "a" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
                 ]
               ]
             ], [
               fhir:index 3 ;
               fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "idasi" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "organization" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "r + '-' + ext" ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid" ]
                   ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "manufacturer" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                   ]
                 ], [
                   fhir:index 3 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/' + %organization.id" ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "name" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "name" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "n" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "organization" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "name" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "n.other" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "meta" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "organization" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "meta" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "meta" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "meta" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "tag" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://algoritmodiscoring" ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "manufactOrg" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ClinicalDocument/body/Vaccinazioni/manufacturerOrganization" ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 12 ;
       fhir:StructureMap.group.rule.name [ fhir:value "part" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "participant" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "part" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PUT" ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "location" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Location" ]
         ]
       ], [
         fhir:index 4 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "location" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "meta" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "part" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "location" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "meta" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "meta" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "part" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "meta" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "tag" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "part" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://algoritmodiscoring" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "part" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ClinicalDocument/body/Vaccinazione/participant" ]
               ]
             ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "role" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "part" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "participantRole" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "partRole" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "identifier" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "partRole" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "location" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "identifier" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ext" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "partRole" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Location?identifier=" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "assigningAuthorityName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "assigningAuthorityName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "assigner" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "a" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "a" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "idasi" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "location" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "r + '-' + ext" ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Location" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid" ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "location" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                 ]
               ], [
                 fhir:index 3 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/' + %location.id" ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 13 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entrirel1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entrirel1" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entrirel1" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obs" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "codecontrol" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '30973-2')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "protocolApplied" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "prot" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "v" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "v" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "int" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "prot" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "doseNumber" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "int.toString()" ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 14 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entrirel2" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entrirel2" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entrirel2" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obs" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "codecontrol" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '59781-5')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "h" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "h" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "expirationDate" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "truncate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "value" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueInteger [ fhir:value "10"^^xsd:integer ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 15 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entrirel4" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entrirel4" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entrirel4" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obs" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "codecontrol" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '59785-6')" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reasonReference" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %observation.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation1" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "entrirel4" ;
                 fhir:index 0
               ], [
                 fhir:value "patient" ;
                 fhir:index 1
               ], [
                 fhir:value "tgt" ;
                 fhir:index 2
               ], [
                 fhir:value "bundle" ;
                 fhir:index 3
               ], [
                 fhir:value "enc" ;
                 fhir:index 4
               ], [
                 fhir:value "observation" ;
                 fhir:index 5
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 16 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entrirel5" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entrirel5" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entrirel5" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obs" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "codecontrol" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = '75321-0') or (code = '5321-0')" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reaction" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reaction" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
               ]
             ], [
               fhir:index 3 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
               ]
             ], [
               fhir:index 4 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
             ], [
               fhir:index 5 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
               ]
             ], [
               fhir:index 6 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
               ]
             ], [
               fhir:index 7 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reaction" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "detail" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 8 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %observation.id" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "obs" ;
                 fhir:index 0
               ], [
                 fhir:value "patient" ;
                 fhir:index 1
               ], [
                 fhir:value "encounter" ;
                 fhir:index 2
               ], [
                 fhir:value "observation" ;
                 fhir:index 3
               ], [
                 fhir:value "bundle" ;
                 fhir:index 4
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 17 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entrirel5" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "substance" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entrirel5" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "obs" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entrirel5" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 12 ;
     fhir:StructureMap.group.name [ fhir:value "ConditionFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "cdaElement" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Condition" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "verifstatus" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "stscode" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "verificationStatus" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "verifstatus" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "stscode" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "codeS" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "verifstatus" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "codeS" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "confirmed" ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "codeS" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://terminology.hl7.org/CodeSystem/condition-ver-status" ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "display" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "codeS" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Confirmed" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
             ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "onset" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "entryRelationship.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "effectiveTime" ;
             fhir:index 0
           ], [
             fhir:value "value" ;
             fhir:index 1
           ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entryR" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "EntryRelObsevation" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "obsentry" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ] ;
           fhir:StructureMap.group.rule.documentation [ fhir:value "toASK" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "category" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "effectiveTime" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "effectiveTime" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entryR" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "entryR2" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryR2" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "obsentry2" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '89261-2'" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "evidence" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "evidence" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
                   ]
                 ], [
                   fhir:index 3 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
                   ]
                 ], [
                   fhir:index 4 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "obsy" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
                   ]
                 ], [
                   fhir:index 5 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "obsy" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
                 ], [
                   fhir:index 6 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
                   ]
                 ], [
                   fhir:index 7 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
                   ]
                 ], [
                   fhir:index 8 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "evidence" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "detail" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                   ]
                 ], [
                   fhir:index 9 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obsy.id" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.dependent [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
                   fhir:StructureMap.group.rule.dependent.variable [
                     fhir:value "obsentry2" ;
                     fhir:index 0
                   ], [
                     fhir:value "patient" ;
                     fhir:index 1
                   ], [
                     fhir:value "encounter" ;
                     fhir:index 2
                   ], [
                     fhir:value "obsy" ;
                     fhir:index 3
                   ], [
                     fhir:value "bundle" ;
                     fhir:index 4
                   ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "clinicalStatus2" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.condition [ fhir:value "code = '33999-4'" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "clinicalstatus" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "clinicalStatus" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "clinicalstatus" ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "val" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "clinicalstatus" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
                     fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
                     ]
                   ] ;
                   fhir:StructureMap.group.rule.rule [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA9041-0')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "resolved" ]
                       ]
                     ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA18632-2')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "inactive" ]
                       ]
                     ]
                   ], [
                     fhir:index 2 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                       fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'LA16666-2')" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "active" ]
                       ]
                     ]
                   ], [
                     fhir:index 3 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "val" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://terminology.hl7.org/CodeSystem/condition-clinical" ]
                       ]
                     ]
                   ], [
                     fhir:index 4 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "display" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "val" ] ;
                       fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                       fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
                       ], [
                         fhir:index 1 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                       ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
                   ] ;
                   fhir:StructureMap.group.rule.rule [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
                     fhir:StructureMap.group.rule.source [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                       fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                       fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
                     ] ;
                     fhir:StructureMap.group.rule.target [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.context [ fhir:value "clinicalstatus" ] ;
                       fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                       fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                       fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                       fhir:StructureMap.group.rule.target.parameter [
                         fhir:index 0 ;
                         fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
                       ]
                     ]
                   ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "severity" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.condition [ fhir:value "code = 'SEV'" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "obsentry2" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "severity" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryR2" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 13 ;
     fhir:StructureMap.group.name [ fhir:value "FamilyMemberFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "organizer" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "FamilyMemberHistory" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "patReference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "patient" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "date" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "date" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "date" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDate" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "relationship" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "subject" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "relatedSub" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "subject" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "relatedSubject" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "relatedSubject" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "relationshipCode" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "relatedSubject" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "relationship" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "subject" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "relatedSubject" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "subject" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "subject" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "sex" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "sex" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "subject" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "administrativeGenderCode" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "administrativeGenderCode" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "sex" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "gender" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "administrativeGenderCode" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "sexCode" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "sexCode" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#cm-v3-administrative-gender" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "administrativeGenderCode" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/administrative-gender" ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "administrativeGenderCode" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "dn" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "dn" ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "component" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "condition" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "condition" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "observation" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "condition" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "codeable" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "condition" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "outcome" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ] ;
           fhir:StructureMap.group.rule.documentation [ fhir:value "observation.effectiveTime as effectiveTime -> condition.onset = create('Period') as value then IVLTSPeriod(effectiveTime, value) \"valuePeriod\";" ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "EntryRel" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "entryR" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "obser" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "entryR" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "obs" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "insorgenza" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
                 fhir:StructureMap.group.rule.source.condition [ fhir:value "(code.code = '35267-4')" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "condition" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "onset" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "Age" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Age" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "age" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "valueAge" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "valueAge" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "unit" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "unit" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "unit" ]
                     ]
                   ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "unit" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "unit" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "unit" ]
                     ]
                   ]
                 ], [
                   fhir:index 3 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://unitsofmeasure.org" ]
                     ]
                   ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "death" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
                 fhir:StructureMap.group.rule.source.condition [ fhir:value "(code.code = '39016-1')" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "obs" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "deceased" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "Age" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Age" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "age" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "valueAge" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "valueAge" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "unit" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "unit" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "unit" ]
                     ]
                   ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "unit" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "unit" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "unit" ]
                     ]
                   ]
                 ], [
                   fhir:index 3 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "value" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "Age" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://unitsofmeasure.org" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 14 ;
     fhir:StructureMap.group.name [ fhir:value "Practitioner" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "performer" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "resurceCreation" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e22" ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e22" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PUT" ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e22" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "practitioner1" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "participant" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "assignedEntity" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "assignedEntity" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "participant" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "participant" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "time" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "time" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "participant" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "time" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "time" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "time" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "participant" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "time" ;
               fhir:index 0
             ], [
               fhir:value "value" ;
               fhir:index 1
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "identifier" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "identifier" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ext" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "assigningAuthorityName" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "assigningAuthorityName" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "assigner" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "a" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "a" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid22" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "r + '-' + ext" ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "e22" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Practitioner/" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid22" ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "participant" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "individual" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                 ]
               ], [
                 fhir:index 3 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Practitioner/' + %practitioner1.id" ]
                 ]
               ]
             ]
           ] ;
           fhir:StructureMap.group.rule.documentation [ fhir:value "src.time as time -> participant.period as period then{" ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "2.16.840.1.113883.2.9.4.3.2" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(root = '2.16.840.1.113883.2.9.4.3.2')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner?identifier=" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
               ]
             ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "diverso" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source.condition [ fhir:value "(root != '2.16.840.1.113883.2.9.4.3.2')" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner?identifier=" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
               ]
             ]
           ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.name [ fhir:value "meta" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "meta" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "meta" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "meta" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "tag" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://algoritmodiscoring" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ClinicalDocument/body/VisiteRicoveri/performer/" ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.name [ fhir:value "addr" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "addr" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "address" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.name [ fhir:value "telecom" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "telecom" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "telecom" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.name [ fhir:value "partname" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assignedEntity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "assignedPerson" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "person" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "name" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "person" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "name" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "name" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "birthTime" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "person" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "birthTime" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "birthDate" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 15 ;
     fhir:StructureMap.group.name [ fhir:value "CarePlanFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "entry" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "CarePlan" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
         ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "intent" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "intent" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "plan" ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "activityIni" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "activity" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "activity" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "detail" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "activity" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "detail" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "detail" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entryObs" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "activity" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "detail" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "obs1" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "observation" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
                 ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
                 ]
               ], [
                 fhir:index 3 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "obs1" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
                 ]
               ], [
                 fhir:index 4 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "obs1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
               ], [
                 fhir:index 5 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
                 ]
               ], [
                 fhir:index 6 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
                 ]
               ], [
                 fhir:index 7 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "detail" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "reasonReference" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                 ]
               ], [
                 fhir:index 8 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obs1.id" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.dependent [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
                 fhir:StructureMap.group.rule.dependent.variable [
                   fhir:value "observation" ;
                   fhir:index 0
                 ], [
                   fhir:value "patient" ;
                   fhir:index 1
                 ], [
                   fhir:value "encounter" ;
                   fhir:index 2
                 ], [
                   fhir:value "obs1" ;
                   fhir:index 3
                 ], [
                   fhir:value "bundle" ;
                   fhir:index 4
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "entrySub" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "substanceAdministration" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "substanceAdministration" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "activity" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "activity" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "Terapie" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "substanceAdministration" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "e2" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
               ]
             ], [
               fhir:index 3 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "medre1" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "MedicationRequest" ]
               ]
             ], [
               fhir:index 4 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "medre1" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid2" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
             ], [
               fhir:index 5 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/MedicationRequest/" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid2" ]
               ]
             ], [
               fhir:index 6 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "MedicationRequest" ]
               ]
             ], [
               fhir:index 7 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "activity" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 8 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/MedicationRequest/' + %medre1.id" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "MedicationRequest" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "substanceAdministration" ;
                 fhir:index 0
               ], [
                 fhir:value "patient" ;
                 fhir:index 1
               ], [
                 fhir:value "encounter" ;
                 fhir:index 2
               ], [
                 fhir:value "medre1" ;
                 fhir:index 3
               ], [
                 fhir:value "bundle" ;
                 fhir:index 4
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "proc" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "procedureC" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e8" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "procedure" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid8" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e8" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Procedure/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid8" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Procedure" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "activity" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "outcomeReference" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Procedure/' + %procedure.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "Procedure" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "procedureC" ;
               fhir:index 0
             ], [
               fhir:value "patient" ;
               fhir:index 1
             ], [
               fhir:value "encounter" ;
               fhir:index 2
             ], [
               fhir:value "procedure" ;
               fhir:index 3
             ], [
               fhir:value "bundle" ;
               fhir:index 4
             ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "viste" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "encounter" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "encounterCDA" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e3" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "encounterFHIR" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid3" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e3" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Encounter/" ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid3" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Encounter" ]
             ]
           ], [
             fhir:index 7 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "encounter" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
             ]
           ], [
             fhir:index 8 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Encounter/' + %encounterFHIR.id" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "refPatient" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.documentation [ fhir:value "encounterCDA -> encounterFHIR.partOf = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"encounterHeader\";" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "statusCode.exists().not()" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
               ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.name [ fhir:value "class" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "class" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "class" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "code" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "system" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "system" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "displayName" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "displayName" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "display" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "cast" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "display" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "string" ]
                 ]
               ]
             ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "type" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "type" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
                 ]
               ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.name [ fhir:value "efft" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "encounterCDA" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "encounterFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "period" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "period" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "start" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "start" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.dependent [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
                 fhir:StructureMap.group.rule.dependent.variable [
                   fhir:value "effectiveTime" ;
                   fhir:index 0
                 ], [
                   fhir:value "start" ;
                   fhir:index 1
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "act" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "act" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "activity" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "outcomeCodeableConcept" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "text" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "activity" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "progress" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "progress" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Annotation" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "progress" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
                 ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "efft" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "act" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "effectiveTime" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "detail" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "scheduled" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "period" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "effectiveTime" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "period" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "start" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "start" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.dependent [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
                 fhir:StructureMap.group.rule.dependent.variable [
                   fhir:value "effectiveTime" ;
                   fhir:index 0
                 ], [
                   fhir:value "start" ;
                   fhir:index 1
                 ]
               ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "act" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "detail" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "completed" ]
               ]
             ]
           ]
         ]
       ]
     ]
  ], [
     fhir:index 16 ;
     fhir:StructureMap.group.name [ fhir:value "MedicationRequest" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "substanceAdministration" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "MedicationRequest" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "default  + mandatory" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "intent" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "intent" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "order" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.encounter = create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %encounter.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "st" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "statusCode.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "sc" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "codeS" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "sc" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "cos" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "cos" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "#MedicationStatusMap" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code" ]
           ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "note" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "txt" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "note" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "txt" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reference" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "note" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reference.value" ]
           ]
         ]
       ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "period" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "IVL_TS" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "dosageInstruction" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "eff" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Timing" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "rep" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "eff" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "timing" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "repeat" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "rep" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "eff" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "rep" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "bounds" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
               ]
             ] ;
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "eff" ;
                 fhir:index 0
               ], [
                 fhir:value "value" ;
                 fhir:index 1
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "period" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "EIVL_TS" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "effe" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "dosageInstruction" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "effe" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Timing" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "rep" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "effe" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "timing" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "repeat" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "rep" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "eventCode" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "effe" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "eventCode" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ev" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "rep" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "when" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ev.code" ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 8 ;
       fhir:StructureMap.group.rule.name [ fhir:value "tim" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "IVL_TS" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "dosageInstruction" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Timing" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "timing" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "event" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "eff.value" ]
         ]
       ]
     ], [
       fhir:index 9 ;
       fhir:StructureMap.group.rule.name [ fhir:value "eff" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.type [ fhir:value "PIVL_TS" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "dosageInstruction" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "dosage" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "cod" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "eff" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "dosage" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "timing" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Timing" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "periodTiming" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "eff" ;
             fhir:index 0
           ], [
             fhir:value "timing" ;
             fhir:index 1
           ]
         ]
       ]
     ], [
       fhir:index 10 ;
       fhir:StructureMap.group.rule.name [ fhir:value "condition" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(src.doseQuantity.exists() or src.rateQuantity.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "dosageIn" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "dosageInstruction" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "dosageInstruction" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Dosage" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "doseQuantity" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "doseQuantity" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "doseQuant" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ot" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ot" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "ot" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "dosageRate" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "doseAndRate" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "dosageRate" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "d" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageRate" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "dose" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "d" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Range" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "l" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.unit" ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "h" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "doseQuant" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.unit" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "rate" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "rateQuantity" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "rateQuantity" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ot" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "originalText" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "ot" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "ot" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "dosageRate" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "doseAndRate" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "dosageRate" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "dosageRate" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "rate" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "d" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Range" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "l" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "low" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "low" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "lo" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "l" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "lo.unit" ]
                     ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "d" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "h" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "SimpleQuantity" ]
                   ]
                 ] ;
                 fhir:StructureMap.group.rule.rule [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.value" ]
                     ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.name [ fhir:value "high" ] ;
                   fhir:StructureMap.group.rule.source [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.source.context [ fhir:value "rateQuantity" ] ;
                     fhir:StructureMap.group.rule.source.element [ fhir:value "high" ] ;
                     fhir:StructureMap.group.rule.source.variable [ fhir:value "hi" ]
                   ] ;
                   fhir:StructureMap.group.rule.target [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.context [ fhir:value "h" ] ;
                     fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                     fhir:StructureMap.group.rule.target.element [ fhir:value "unit" ] ;
                     fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                     fhir:StructureMap.group.rule.target.parameter [
                       fhir:index 0 ;
                       fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "hi.unit" ]
                     ]
                   ]
                 ]
               ]
             ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.name [ fhir:value "route" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "routeCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "route" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.name [ fhir:value "site" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "approachSiteCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "site" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.name [ fhir:value "site" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "targetSiteCode" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dosageInstruction" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "site" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ]
       ]
     ], [
       fhir:index 11 ;
       fhir:StructureMap.group.rule.name [ fhir:value "medication" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "consumable" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "consumable" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
         ]
       ], [
         fhir:index 3 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "medication" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Medication" ]
         ]
       ], [
         fhir:index 4 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "medication" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
       ], [
         fhir:index 5 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Medication/" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
         ]
       ], [
         fhir:index 6 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Medication" ]
         ]
       ], [
         fhir:index 7 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "medication" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "medref" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 8 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "medref" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Medication/' + %medication.id" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "Medication" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "src" ;
           fhir:index 0
         ], [
           fhir:value "medication" ;
           fhir:index 1
         ], [
           fhir:value "patient" ;
           fhir:index 2
         ], [
           fhir:value "bundle" ;
           fhir:index 3
         ]
       ]
     ], [
       fhir:index 12 ;
       fhir:StructureMap.group.rule.name [ fhir:value "entryR" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "entryRelationship" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "supply" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "entryRelationship" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "supply" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "supply" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "dispenseRequest" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "dispenseRequest" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "quantity" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "supply" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "quantityCDA" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "dispenseRequest" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "quantity" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "quantityFHIR" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "quantityCDA" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "quantityFHIR" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "quantityCDA.value" ]
               ]
             ]
           ]
         ]
       ]
     ], [
       fhir:index 13 ;
       fhir:StructureMap.group.rule.name [ fhir:value "Partecipant" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "participant" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "participant" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "function" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "participant" ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "Practitioner" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "participant" ;
             fhir:index 0
           ], [
             fhir:value "tgt" ;
             fhir:index 1
           ], [
             fhir:value "bundle" ;
             fhir:index 2
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "autor" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "participant" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "authoredOn" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
         ]
       ]
     ]
  ], [
     fhir:index 17 ;
     fhir:StructureMap.group.name [ fhir:value "OrganizationAffiliation" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "act" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "enc" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "OrganizationAffiliation" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "code = 'active'" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "active" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueBoolean [ fhir:value "true"^^xsd:boolean ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src.code -> tgt.specialty as specialty then{" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(code = 'active').not()" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "active" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueBoolean [ fhir:value "false"^^xsd:boolean ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "effectiveTime" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "period" ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "a" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "specialty" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "spec" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "CodeableConcept" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "spec" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "cd" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "code" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "spec" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cd" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "cd" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code.code" ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "code" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "cd" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code.displayName" ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "cd" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
               fhir:StructureMap.group.rule.target.parameter [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
               ], [
                 fhir:index 2 ;
                 fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
               ]
             ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "entry" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "entryRelationship" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "entry" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "act" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "act" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "a" ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "ref" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "a" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "reff" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "spec" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reff.value" ]
                 ]
               ]
             ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src.code -> tgt.specialty;" ]
     ]
  ], [
     fhir:index 18 ;
     fhir:StructureMap.group.name [ fhir:value "DiagnosticReportFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "organizer" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "enc" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "DiagnosticReport" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "reference" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "subject" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Patient/' + %patient.id" ]
         ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src -> tgt.encounter=create('Reference') as reference,  reference.reference = ('https://example/Encounter/' + %enc.id) \"reference\";" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "code = 'completed'" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "final" ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "value1" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(value.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "eff" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "valuePeriod" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(low.exists())" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "value" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
         ]
       ] ;
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "effectiveTime" ;
           fhir:index 0
         ], [
           fhir:value "value" ;
           fhir:index 1
         ]
       ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "component" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "component" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "component" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "hasMember" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "component" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "observation" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "observation" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "ei" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "obsi" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "obsi" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "uuidi" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ei" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Observation/" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuidi" ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Observation" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "result" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Observation/' + %obsi.id" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "Observation" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "observation" ;
             fhir:index 0
           ], [
             fhir:value "patient" ;
             fhir:index 1
           ], [
             fhir:value "enc" ;
             fhir:index 2
           ], [
             fhir:value "obsi" ;
             fhir:index 3
           ], [
             fhir:value "bundle" ;
             fhir:index 4
           ]
         ]
       ]
     ]
  ], [
     fhir:index 19 ;
     fhir:StructureMap.group.name [ fhir:value "EncounterFunction" ] ;
     fhir:StructureMap.group.typeMode [ fhir:value "none" ] ;
     fhir:StructureMap.group.input [
       fhir:index 0 ;
       fhir:StructureMap.group.input.name [ fhir:value "src" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "cdaElement" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.input.name [ fhir:value "patient" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Patient" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.input.name [ fhir:value "encounter" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.input.name [ fhir:value "tgt" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Encounter" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.input.name [ fhir:value "bundle" ] ;
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ] ;
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]
     ] ;
     fhir:StructureMap.group.rule [
       fhir:index 0 ;
       fhir:StructureMap.group.rule.name [ fhir:value "id" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 1 ;
       fhir:StructureMap.group.rule.name [ fhir:value "statusCode" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "statusCode" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
       ]
     ], [
       fhir:index 2 ;
       fhir:StructureMap.group.rule.name [ fhir:value "status" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "statusCode.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "status" ] ;
         fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "unknown" ]
         ]
       ]
     ], [
       fhir:index 3 ;
       fhir:StructureMap.group.rule.name [ fhir:value "co" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "code" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "class" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "class" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "code" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code.code" ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "display" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "code" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "code.displayName" ]
           ]
         ]
       ], [
         fhir:index 2 ;
         fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "codeSystem" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "class" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
           ]
         ]
       ]
     ], [
       fhir:index 4 ;
       fhir:StructureMap.group.rule.name [ fhir:value "where" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "effectiveTime.low.exists() or effectiveTime.high.exists()" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "effectiveTime" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "eff" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "IVLTSPeriod" ] ;
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "eff" ;
             fhir:index 0
           ], [
             fhir:value "period" ;
             fhir:index 1
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src.effectiveTime as effective -> tgt.period as period then{" ]
     ], [
       fhir:index 5 ;
       fhir:StructureMap.group.rule.name [ fhir:value "where" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.condition [ fhir:value "effectiveTime.low.exists().not() or effectiveTime.high.exists().not()" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "efft" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "effectiveTime" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "effectivetime1" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Period" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "effectivetime1" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "period" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "start" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "start" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "dateTime" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "effectivetime1" ;
               fhir:index 0
             ], [
               fhir:value "start" ;
               fhir:index 1
             ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "effectiveTime = time-stamp" ]
     ], [
       fhir:index 6 ;
       fhir:StructureMap.group.rule.name [ fhir:value "text" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "text" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "tx" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "type" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "ty" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "textType" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "tx" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "reff" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "ty" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "text" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "reff.value" ]
           ]
         ]
       ] ;
       fhir:StructureMap.group.rule.documentation [ fhir:value "src.effectiveTime as eff where (value.exists()) -> tgt.period = create('dateTime') as value then TSDateTime(eff, value) \"value1\";" ]
     ], [
       fhir:index 7 ;
       fhir:StructureMap.group.rule.name [ fhir:value "01" ] ;
       fhir:StructureMap.group.rule.source [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.source.context [ fhir:value "src" ] ;
         fhir:StructureMap.group.rule.source.element [ fhir:value "performer" ] ;
         fhir:StructureMap.group.rule.source.variable [ fhir:value "performer" ]
       ] ;
       fhir:StructureMap.group.rule.target [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
         fhir:StructureMap.group.rule.target.element [ fhir:value "participant" ] ;
         fhir:StructureMap.group.rule.target.variable [ fhir:value "part" ]
       ] ;
       fhir:StructureMap.group.rule.rule [
         fhir:index 0 ;
         fhir:StructureMap.group.rule.name [ fhir:value "period" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "performer" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "part" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "period" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "period" ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "val" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "performer" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "time" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "time" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "period" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "start" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "start" ]
           ] ;
           fhir:StructureMap.group.rule.dependent [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.dependent.name [ fhir:value "TSDateTime" ] ;
             fhir:StructureMap.group.rule.dependent.variable [
               fhir:value "time" ;
               fhir:index 0
             ], [
               fhir:value "start" ;
               fhir:index 1
             ]
           ]
         ]
       ], [
         fhir:index 1 ;
         fhir:StructureMap.group.rule.name [ fhir:value "performer" ] ;
         fhir:StructureMap.group.rule.source [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.source.context [ fhir:value "performer" ] ;
           fhir:StructureMap.group.rule.source.element [ fhir:value "assignedEntity" ] ;
           fhir:StructureMap.group.rule.source.variable [ fhir:value "assentity" ]
         ] ;
         fhir:StructureMap.group.rule.target [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "e1" ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 2 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "POST" ]
           ]
         ], [
           fhir:index 3 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "practitionerRole" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PractitionerRole" ]
           ]
         ], [
           fhir:index 4 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "practitionerRole" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid1" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]
         ], [
           fhir:index 5 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "e1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/PractitionerRole/" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid1" ]
           ]
         ], [
           fhir:index 6 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PractitionerRole" ]
           ]
         ], [
           fhir:index 7 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "tgt" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "participant" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "participant1" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
           ]
         ], [
           fhir:index 8 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "participant1" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "individual" ] ;
           fhir:StructureMap.group.rule.target.variable [ fhir:value "referencepart" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
           ]
         ], [
           fhir:index 9 ;
           fhir:StructureMap.group.rule.target.context [ fhir:value "referencepart" ] ;
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
           fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
           fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
           fhir:StructureMap.group.rule.target.parameter [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/PractitionerRole/' + %practitionerRole.id" ]
           ]
         ] ;
         fhir:StructureMap.group.rule.rule [
           fhir:index 0 ;
           fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
             fhir:StructureMap.group.rule.source.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "practitionerRole" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
           ]
         ], [
           fhir:index 1 ;
           fhir:StructureMap.group.rule.name [ fhir:value "assignedEntity" ] ;
           fhir:StructureMap.group.rule.source [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
           ] ;
           fhir:StructureMap.group.rule.target [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "bundle" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "entry" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "e2" ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "BackboneElement" ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "method" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "PUT" ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
             fhir:StructureMap.group.rule.target.element [ fhir:value "resource" ] ;
             fhir:StructureMap.group.rule.target.variable [ fhir:value "practitioner" ] ;
             fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner" ]
             ]
           ] ;
           fhir:StructureMap.group.rule.rule [
             fhir:index 0 ;
             fhir:StructureMap.group.rule.name [ fhir:value "meta" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "meta" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "meta" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "coding" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "meta" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "tag" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Coding" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://algoritmodiscoring" ]
                   ]
                 ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "code" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "coding" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "code" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "ClinicalDocument/body/encounter/performer" ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 1 ;
             fhir:StructureMap.group.rule.name [ fhir:value "identifier" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "identifier" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "identifier" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "root1" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "system" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "translate" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "r" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "http://hl7.org/fhir/ConceptMap/special-oid2uri" ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "uri" ]
                 ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "ext" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner?identifier=" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                   ]
                 ]
               ]
             ], [
               fhir:index 2 ;
               fhir:StructureMap.group.rule.name [ fhir:value "assigningAuthorityName" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "assigningAuthorityName" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "s" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "identifier" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "assigner" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "a" ]
               ], [
                 fhir:index 1 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "a" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "display" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "copy" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "s" ]
                 ]
               ]
             ], [
               fhir:index 3 ;
               fhir:StructureMap.group.rule.name [ fhir:value "r" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "root" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "r" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "performer" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "id" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "uuid2" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "r + '-' + ext" ]
                   ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "e2" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "fullUrl" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "https://example/Practitioner/" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid2" ]
                   ]
                 ], [
                   fhir:index 2 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "practitionerRole" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "practitioner" ] ;
                   fhir:StructureMap.group.rule.target.variable [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Reference" ]
                   ]
                 ], [
                   fhir:index 3 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "reference" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "evaluate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'https://example/Practitioner/' + %practitioner.id" ]
                   ]
                 ]
               ]
             ]
           ], [
             fhir:index 2 ;
             fhir:StructureMap.group.rule.name [ fhir:value "2.16.840.1.113883.2.9.4.3.2" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(root = '2.16.840.1.113883.2.9.4.3.2')" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner?identifier=" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ]
             ]
           ], [
             fhir:index 3 ;
             fhir:StructureMap.group.rule.name [ fhir:value "2.16.840.1.113883.2.9.4.3.2" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "id" ] ;
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(root != '2.16.840.1.113883.2.9.4.3.2')" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "UUID" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "id" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "extension" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "ext" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "request" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "url" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "append" ] ;
                 fhir:StructureMap.group.rule.target.parameter [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "Practitioner?identifier=" ]
                 ], [
                   fhir:index 1 ;
                   fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "ext" ]
                 ]
               ]
             ]
           ], [
             fhir:index 4 ;
             fhir:StructureMap.group.rule.name [ fhir:value "addr" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "addr" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "address" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 5 ;
             fhir:StructureMap.group.rule.name [ fhir:value "telecom" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "telecom" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
             ] ;
             fhir:StructureMap.group.rule.target [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
               fhir:StructureMap.group.rule.target.element [ fhir:value "telecom" ] ;
               fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
               fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
             ]
           ], [
             fhir:index 6 ;
             fhir:StructureMap.group.rule.name [ fhir:value "name" ] ;
             fhir:StructureMap.group.rule.source [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.source.context [ fhir:value "assentity" ] ;
               fhir:StructureMap.group.rule.source.element [ fhir:value "assignedPerson" ] ;
               fhir:StructureMap.group.rule.source.variable [ fhir:value "person" ]
             ] ;
             fhir:StructureMap.group.rule.rule [
               fhir:index 0 ;
               fhir:StructureMap.group.rule.name [ fhir:value "name" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "person" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "name" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "vvv" ]
               ] ;
               fhir:StructureMap.group.rule.target [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
                 fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                 fhir:StructureMap.group.rule.target.element [ fhir:value "name" ] ;
                 fhir:StructureMap.group.rule.target.variable [ fhir:value "vvv" ] ;
                 fhir:StructureMap.group.rule.target.transform [ fhir:value "create" ]
               ]
             ], [
               fhir:index 1 ;
               fhir:StructureMap.group.rule.name [ fhir:value "birth" ] ;
               fhir:StructureMap.group.rule.source [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.source.context [ fhir:value "person" ] ;
                 fhir:StructureMap.group.rule.source.element [ fhir:value "birthTime" ] ;
                 fhir:StructureMap.group.rule.source.variable [ fhir:value "birthTime" ]
               ] ;
               fhir:StructureMap.group.rule.rule [
                 fhir:index 0 ;
                 fhir:StructureMap.group.rule.name [ fhir:value "value" ] ;
                 fhir:StructureMap.group.rule.source [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.source.context [ fhir:value "birthTime" ] ;
                   fhir:StructureMap.group.rule.source.element [ fhir:value "value" ] ;
                   fhir:StructureMap.group.rule.source.variable [ fhir:value "date" ]
                 ] ;
                 fhir:StructureMap.group.rule.target [
                   fhir:index 0 ;
                   fhir:StructureMap.group.rule.target.context [ fhir:value "practitioner" ] ;
                   fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ] ;
                   fhir:StructureMap.group.rule.target.element [ fhir:value "birthDate" ] ;
                   fhir:StructureMap.group.rule.target.transform [ fhir:value "truncate" ] ;
                   fhir:StructureMap.group.rule.target.parameter [
                     fhir:index 0 ;
                     fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "date" ]
                   ], [
                     fhir:index 1 ;
                     fhir:StructureMap.group.rule.target.parameter.valueInteger [ fhir:value "10"^^xsd:integer ]
                   ]
                 ]
               ]
             ]
           ]
         ]
       ]
     ]
  ] .

# - ontology header ------------------------------------------------------------

<http://hl7.org/fhir/StructureMap/cda2fhirPs.ttl> a owl:Ontology ;
  owl:imports fhir:fhir.ttl ;
  owl:versionIRI <http://build.fhir.org/StructureMap/cda2fhirPs.ttl> .