CH RAD-Order (R4)
0.1.0 - STU 1 Ballot

CH RAD-Order (R4), published by HL7 Switzerland. This is not an authorized publication; it is the continuous build for version 0.1.0). This version is based on the current content of https://github.com/hl7ch/ch-rad-order/ and changes regularly. See the Directory of published versions

: RadOrderQrToBundle - TTL Representation

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

 a fhir:StructureMap;
  fhir:nodeRole fhir:treeRoot;
  fhir:Resource.id [ fhir:value "RadOrderQrToBundle"];
  fhir:Resource.meta [
     fhir:Meta.versionId [ fhir:value "4" ];
     fhir:Meta.lastUpdated [ fhir:value "2022-01-03T15:58:34.931+00:00"^^xsd:dateTime ]
  ];
  fhir:DomainResource.text [
     fhir:Narrative.status [ fhir:value "generated" ];
     fhir:Narrative.div "<div xmlns=\"http://www.w3.org/1999/xhtml\">\n         <pre>map &quot;http://fhir.ch/ig/ch-rad-order/StructureMap/RadOrderQrToBundle&quot; = &quot;RadOrderQrToBundle&quot;\n\n// Radiologoy QuestionnaireResponse to Bundle\n\nuses &quot;http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse&quot; alias QuestionnaireResponse as source\nuses &quot;http://hl7.org/fhir/StructureDefinition/Bundle&quot; alias Bundle as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/Patient&quot; alias Patient as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/Organization&quot; alias Organization as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/Practitioner&quot; alias Practitioner as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/PractitionerRole&quot; alias PractitionerRole as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/ServiceRequest&quot; alias ServiceRequest as target\nuses &quot;http://hl7.org/fhir/StructureDefinition/BackboneElement&quot; alias BackboneElement as target\n\nimports &quot;http://fhir.ch/ig/ch-orf/StructureMap/OrfQrToBundle&quot;\n\ngroup RadOrderQrToBundle(source qr : QuestionnaireResponse, target bundle : Bundle) {\n  qr -&gt;  bundle.identifier as documentIdentifier,  documentIdentifier.system = 'urn:ietf:rfc:3986',  uuid() as uuidDoc,  documentIdentifier.value = ('urn:uuid:' + uuidDoc) &quot;documentIdentifier&quot;;\n  qr as qrcp -&gt;  bundle.entry as e,  e.resource = create('Composition') as composition,  composition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  bundle.entry as e2,  bundle.timestamp = (now()) as timestamp,  composition.date = timestamp,  e2.resource = create('Patient') as patient,  patient.id = uuid() as uuid2,  e2.fullUrl = ('urn:uuid:' + uuid2),  bundle.entry as e4,  e4.resource = qrcp as questionnaireresp,  questionnaireresp.id = uuid() as uuid4,  e4.fullUrl = ('urn:uuid:' + uuid4),  bundle.entry as e5,  e5.resource = create('ServiceRequest') as servicerequest,  servicerequest.id = uuid() as uuid5,  e5.fullUrl = ('urn:uuid:' + uuid5) then {\n    qr.questionnaire as can -&gt;  bundle.entry as e6,  e6.resource = (can.resolve()) as q,  q.id = uuid() as uuid6,  e6.fullUrl = append('urn:uuid:', uuid6) then QrToBundle(qr, q, patient, questionnaireresp, servicerequest, composition, bundle) &quot;orfbundle&quot;;\n    qr then RadOrderQrToServiceRequest(qr, patient, bundle, composition, servicerequest) &quot;servicerequest&quot;;\n  } &quot;orfbundle&quot;;\n}\n\ngroup RadOrderQrToServiceRequest(source qr : QuestionnaireResponse, target patient : Patient, target bundle : Bundle, target composition : Composition, target serviceRequest : ServiceRequest) {\n  qr.item as grp where linkId = 'requestedService' then RequestedServiceItems(grp, serviceRequest) &quot;requestedService&quot;;\n  qr.item as grp where linkId = 'reason' then ReasonServiceItems(grp, serviceRequest) &quot;reason&quot;;\n  qr.item as grp where linkId = 'imagingService' then ImagingServiceItems(grp, serviceRequest) &quot;imagingService&quot;;\n  qr.item as grp where linkId = 'orderDetail' then OrderDetailServiceItems(grp, serviceRequest) &quot;orderDetail&quot;;\n  qr.item as grp where linkId = 'desiredRadiologist' then DesiredRadiologistServiceItems(grp, bundle, serviceRequest) &quot;desiredRadiologist&quot;;\n  qr.item as grp where linkId = 'diagnosisList' then DiagnosisListServiceItems(grp, patient, bundle, serviceRequest) &quot;diagnosisList&quot;;\n  qr.item as grp where linkId = 'caveat' then CaveatServiceItems(grp, patient, bundle, serviceRequest) &quot;Caveat&quot;;\n  qr.item as grp where linkId = 'previousResults' then PreviousImagingStudyResults(grp, bundle, serviceRequest, patient) &quot;previousResults&quot;;\n}\n\ngroup RequestedServiceItems(source src : BackboneElement, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'requestedService.service') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.category as cc,  cc.coding = coding &quot;service&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup ReasonServiceItems(source src : BackboneElement, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'reason.question') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : string as value -&gt;  serviceRequest.reasonCode as reasonCode,  reasonCode.text = value &quot;question&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup ImagingServiceItems(source src : BackboneElement, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'imagingService.type') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.code as code,  code.coding = coding &quot;service&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup OrderDetailServiceItems(source src : BackboneElement, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'orderDetail.imagingRegion') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.orderDetail as cc,  cc.extension as ext,  ext.url = 'http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type',  ext.value = create('Coding') as coding,  coding.system = 'http://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type',  coding.code = 'imagingRegion',  cc.coding = coding &quot;imagingRegion&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'orderDetail.imagingFocus') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.bodySite as cc,  cc.coding = coding &quot;imagingFocus&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'orderDetail.laterality') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.orderDetail as cc,  cc.extension as ext,  ext.url = 'http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type',  ext.value = create('Coding') as coding,  coding.system = 'http://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type',  coding.code = 'laterality',  cc.coding = coding &quot;laterality&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'orderDetail.viewType') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.orderDetail as cc,  cc.extension as ext,  ext.url = 'http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type',  ext.value = create('Coding') as coding,  coding.system = 'http://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type',  coding.code = 'viewType',  cc.coding = coding &quot;viewType&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'orderDetail.maneuverType') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.orderDetail as cc,  cc.extension as ext,  ext.url = 'http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type',  ext.value = create('Coding') as coding,  coding.system = 'http://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type',  coding.code = 'maneuverType',  cc.coding = coding &quot;maneuverType&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'orderDetail.guidanceForAction') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : Coding as coding -&gt;  serviceRequest.orderDetail as cc,  cc.extension as ext,  ext.url = 'http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type',  ext.value = create('Coding') as coding,  coding.system = 'http://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type',  coding.code = 'guidanceForAction',  cc.coding = coding &quot;guidanceForAction&quot;;\n    } &quot;valueCoding&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup DesiredRadiologistServiceItems(source src : BackboneElement, target bundle : Bundle, target serviceRequest : ServiceRequest) {\n  src -&gt;  bundle.entry as e,  e.resource = create('Practitioner') as practitioner,  practitioner.id = uuid() as uuid,  serviceRequest.performer as performer,  performer.reference = ('urn:uuid:' + uuid),  e.fullUrl = ('urn:uuid:' + uuid) then {\n    src.item as item where ((linkId.value = 'desiredRadiologist.familyName') and answer.exists()) -&gt;  practitioner.name as name share name,  name.family = (item.answer.value);\n    src.item as item where ((linkId.value = 'desiredRadiologist.givenName') and answer.exists()) -&gt;  practitioner.name as name share name,  name.given = (item.answer.value);\n  } &quot;performer&quot;;\n}\n\ngroup DiagnosisListServiceItems(source src : BackboneElement, target patient : Patient, target bundle : Bundle, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'diagnosisList.secondaryDiagnosis') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : string as value -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.text = value,  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;secondaryDiagnosis&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup CaveatServiceItems(source src : BackboneElement, target patient : Patient, target bundle : Bundle, target serviceRequest : ServiceRequest) {\n  src.item as item where ((linkId.value = 'caveat.bloodCoagulation') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '64779008',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Blood coagulation disorder (disorder)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;bloodCoagulation&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.renalInsufficiency') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '723188008',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Renal insufficiency (disorder)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) then {\n        // FIXME TODO answer.item as item2 where (linkId.value = 'caveat.renalInsufficiency.creatinineClearance') then RenalInsufficiencyCreatinineServiceItems(item2, patient, bundle, serviceRequest, condition) &quot;RenalInsufficiencyCreatinineServiceItems&quot;;\n        answer.item as item2 where (linkId.value = 'caveat.renalInsufficiency.creatinine') then RenalInsufficiencyCreatinineServiceItems(item2, patient, bundle, serviceRequest, condition) &quot;RenalInsufficiencyCreatinineServiceItems&quot;;\n      } &quot;renalInsufficiency&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.claustrophobia') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '19887002',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Claustrophobia (finding)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;claustrophobia&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.bodyPiercing') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '879862001',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Body piercing (finding)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;bodyPiercing&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.device') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : string as value -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '397578001',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Device in situ (finding)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id),  condition.note as note,  note.text = value &quot;device&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.hyperthyroidism') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '34486009',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Hyperthyroidism (disorder)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;hyperthyroidism&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.diabetes') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '73211009',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Diabetes mellitus (disorder)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;diabetes&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.gravida') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '366321006',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Finding of gravida (finding)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;gravida&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.contrastMediaAllergy') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : boolean as value where answer.valueBoolean -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '293637006',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Allergy to contrast media (finding)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) &quot;contrastMediaAllergy&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n  src.item as item where ((linkId.value = 'caveat.drugPrescription') and answer.exists()) then {\n    item.answer as answer then {\n      answer.value : string as value -&gt;  bundle.entry as e,  e.resource = create('Condition') as condition,  condition.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid),  condition.category as category,  category.coding as coding,  coding.code = 'problem-list-item',  coding.system = 'http://terminology.hl7.org/CodeSystem/condition-category',  coding.display = 'Problem List Item',  condition.code as code,  code.coding as coding2,  coding2.code = '182817000',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Drug prescription (situation)',  condition.subject as subject,  subject.reference = ('urn:uuid:' + patient.id),  condition.note as note,  note.text = value &quot;drugPrescription&quot;;\n    } &quot;valueString&quot;;\n  } &quot;answer&quot;;\n}\n\ngroup RenalInsufficiencyCreatinineServiceItems(source src : BackboneElement, target patient : Patient, target bundle : Bundle, target serviceRequest : ServiceRequest, target condition : Condition) {\n  src -&gt;  bundle.entry as e,  e.resource = create('Observation') as observation,  observation.id = uuid() as uuid,  e.fullUrl = ('urn:uuid:' + uuid),  observation.status = 'final',  observation.code as code,  code.coding as coding2,  coding2.code = '723188008',  coding2.system = 'http://snomed.info/sct',  coding2.display = 'Renal insufficiency (disorder)',  condition.evidence as evidence,  evidence.detail as detail,  detail.reference = ('urn:uuid:' + uuid),  observation.subject as subject,  subject.reference = ('urn:uuid:' + patient.id) then {\n    src.item as item where ((linkId.value = 'caveat.renalInsufficiency.creatinine.quantity') and answer.exists()) then {\n      item.answer as answer then {\n        answer.value : Quantity as value -&gt; observation.value = value;\n      };\n    } &quot;quantity&quot;;\n    src.item as item where ((linkId.value = 'caveat.renalInsufficiency.creatinine.dateTime') and answer.exists()) then {\n      item.answer as answer then {\n        answer.value : dateTime as value -&gt; observation.effective = value;\n      };\n    } &quot;dateTime&quot;;\n  } &quot;observation&quot;;\n}\n\ngroup PreviousImagingStudyResults(source grp : BackboneElement, target bundle : Bundle, target serviceRequest : ServiceRequest, target patient : Patient) {\n  grp.item as item where (linkId.value = 'previousResults.imagingStudy') -&gt;  bundle.entry as e,  e.resource = create('ImagingStudy') as imagingStudy,  imagingStudy.id = uuid() as uuid,  imagingStudy.status = 'available',  imagingStudy.subject as subject,  subject.reference = ('urn:uuid:' + patient.id),  e.fullUrl = append('urn:uuid:', uuid),  serviceRequest.subject as subject,  subject.reference = ('urn:uuid:' + patient.id),  serviceRequest.supportingInfo as supportingInfo,  supportingInfo.reference = ('urn:uuid:' + uuid) then {\n    item.item as dictomitem where ((linkId.value = 'previousResults.imagingStudy.uid') and answer.exists()) -&gt;  imagingStudy.identifier as uid,  uid.system = 'urn:dicom:uid',  uid.use = 'official',  uid.value = ('urn:oid:' + dictomitem.answer.value) &quot;uid&quot;;\n    item.item as dictomitem where ((linkId.value = 'previousResults.imagingStudy.acsn') and answer.exists()) -&gt;  imagingStudy.identifier as acsn,  acsn.type as type,  type.coding as coding,  coding.system = 'http://terminology.hl7.org/CodeSystem/v2-0203',  coding.code = 'ACSN',  acsn.use = 'usual',  acsn.value = (dictomitem.answer.value) &quot;acsn&quot;;\n  } &quot;imagingStudy&quot;;\n}\n\n</pre>\n      </div>"
  ];
  fhir:StructureMap.url [ fhir:value "http://fhir.ch/ig/ch-rad-order/StructureMap/RadOrderQrToBundle"];
  fhir:StructureMap.version [ fhir:value "0.1.0"];
  fhir:StructureMap.name [ fhir:value "RadOrderQrToBundle"];
  fhir:StructureMap.status [ fhir:value "draft"];
  fhir:StructureMap.date [ fhir:value "2022-01-22T19:37:11+00:00"^^xsd:dateTime];
  fhir:StructureMap.publisher [ fhir:value "HL7 Switzerland"];
  fhir:StructureMap.contact [
     fhir:index 0;
     fhir:ContactDetail.name [ fhir:value "Juerg P. Bleuer" ];
     fhir:ContactDetail.telecom [
       fhir:index 0;
       fhir:ContactPoint.system [ fhir:value "url" ];
       fhir:ContactPoint.value [ fhir:value "https://www.hl7.ch" ]     ]
  ];
  fhir:StructureMap.description [ fhir:value "Radiologoy QuestionnaireResponse to Bundle"];
  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 "CH" ]     ]
  ];
  fhir:StructureMap.copyright [ fhir:value "CC-BY-SA-4.0"];
  fhir:StructureMap.structure [
     fhir:index 0;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse";
       fhir:link <http://hl7.org/fhir/StructureDefinition/QuestionnaireResponse>     ];
     fhir:StructureMap.structure.mode [ fhir:value "source" ];
     fhir:StructureMap.structure.alias [ fhir:value "QuestionnaireResponse" ]
  ], [
     fhir:index 1;
     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 2;
     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 "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "Patient" ]
  ], [
     fhir:index 3;
     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 "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "Organization" ]
  ], [
     fhir:index 4;
     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 "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "Practitioner" ]
  ], [
     fhir:index 5;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/PractitionerRole";
       fhir:link <http://hl7.org/fhir/StructureDefinition/PractitionerRole>     ];
     fhir:StructureMap.structure.mode [ fhir:value "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "PractitionerRole" ]
  ], [
     fhir:index 6;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/ServiceRequest";
       fhir:link <http://hl7.org/fhir/StructureDefinition/ServiceRequest>     ];
     fhir:StructureMap.structure.mode [ fhir:value "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "ServiceRequest" ]
  ], [
     fhir:index 7;
     fhir:StructureMap.structure.url [
       fhir:value "http://hl7.org/fhir/StructureDefinition/BackboneElement";
       fhir:link <http://hl7.org/fhir/StructureDefinition/BackboneElement>     ];
     fhir:StructureMap.structure.mode [ fhir:value "target" ];
     fhir:StructureMap.structure.alias [ fhir:value "BackboneElement" ]
  ];
  fhir:StructureMap.import [
     fhir:value "http://fhir.ch/ig/ch-orf/StructureMap/OrfQrToBundle";
     fhir:index 0;
     fhir:link <http://fhir.ch/ig/ch-orf/StructureMap/OrfQrToBundle>
  ];
  fhir:StructureMap.group [
     fhir:index 0;
     fhir:StructureMap.group.name [ fhir:value "RadOrderQrToBundle" ];
     fhir:StructureMap.group.typeMode [ fhir:value "none" ];
     fhir:StructureMap.group.input [
       fhir:index 0;
       fhir:StructureMap.group.input.name [ fhir:value "qr" ];
       fhir:StructureMap.group.input.type [ fhir:value "QuestionnaireResponse" ];
       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 "documentIdentifier" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ]       ];
       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 "documentIdentifier" ]       ], [
         fhir:index 1;
         fhir:StructureMap.group.rule.target.context [ fhir:value "documentIdentifier" ];
         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 "urn:ietf:rfc:3986" ]         ]       ], [
         fhir:index 2;
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "uuidDoc" ];
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]       ], [
         fhir:index 3;
         fhir:StructureMap.group.rule.target.context [ fhir:value "documentIdentifier" ];
         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 "'urn:uuid:' + uuidDoc" ]         ]       ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.rule.name [ fhir:value "orfbundle" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "qrcp" ]       ];
       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 "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 2;
         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 "uuid" ];
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]       ], [
         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 "fullUrl" ];
         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 "'urn:uuid:' + uuid" ]         ]       ], [
         fhir:index 4;
         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 5;
         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.variable [ 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 "now()" ]         ]       ], [
         fhir:index 6;
         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 "date" ];
         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 "timestamp" ]         ]       ], [
         fhir:index 7;
         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 8;
         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 9;
         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 "evaluate" ];
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'urn:uuid:' + uuid2" ]         ]       ], [
         fhir:index 10;
         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 11;
         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 "questionnaireresp" ];
         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 "qrcp" ]         ]       ], [
         fhir:index 12;
         fhir:StructureMap.group.rule.target.context [ fhir:value "questionnaireresp" ];
         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 13;
         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 "evaluate" ];
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'urn:uuid:' + uuid4" ]         ]       ], [
         fhir:index 14;
         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 15;
         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 "servicerequest" ];
         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 "ServiceRequest" ]         ]       ], [
         fhir:index 16;
         fhir:StructureMap.group.rule.target.context [ fhir:value "servicerequest" ];
         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 17;
         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 "evaluate" ];
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'urn:uuid:' + uuid5" ]         ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "orfbundle" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "questionnaire" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "can" ]         ];
         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 "resource" ];
           fhir:StructureMap.group.rule.target.variable [ fhir:value "q" ];
           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 "can.resolve()" ]           ]         ], [
           fhir:index 2;
           fhir:StructureMap.group.rule.target.context [ fhir:value "q" ];
           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 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 "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 "urn:uuid:" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid6" ]           ]         ];
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "QrToBundle" ];
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "qr";
             fhir:index 0           ], [
             fhir:value "q";
             fhir:index 1           ], [
             fhir:value "patient";
             fhir:index 2           ], [
             fhir:value "questionnaireresp";
             fhir:index 3           ], [
             fhir:value "servicerequest";
             fhir:index 4           ], [
             fhir:value "composition";
             fhir:index 5           ], [
             fhir:value "bundle";
             fhir:index 6           ]         ]       ], [
         fhir:index 1;
         fhir:StructureMap.group.rule.name [ fhir:value "servicerequest" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ]         ];
         fhir:StructureMap.group.rule.dependent [
           fhir:index 0;
           fhir:StructureMap.group.rule.dependent.name [ fhir:value "RadOrderQrToServiceRequest" ];
           fhir:StructureMap.group.rule.dependent.variable [
             fhir:value "qr";
             fhir:index 0           ], [
             fhir:value "patient";
             fhir:index 1           ], [
             fhir:value "bundle";
             fhir:index 2           ], [
             fhir:value "composition";
             fhir:index 3           ], [
             fhir:value "servicerequest";
             fhir:index 4           ]         ]       ]     ]
  ], [
     fhir:index 1;
     fhir:StructureMap.group.name [ fhir:value "RadOrderQrToServiceRequest" ];
     fhir:StructureMap.group.typeMode [ fhir:value "none" ];
     fhir:StructureMap.group.input [
       fhir:index 0;
       fhir:StructureMap.group.input.name [ fhir:value "qr" ];
       fhir:StructureMap.group.input.type [ fhir:value "QuestionnaireResponse" ];
       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 "bundle" ];
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 3;
       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 4;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "requestedService" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'requestedService'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "RequestedServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "serviceRequest";
           fhir:index 1         ]       ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.rule.name [ fhir:value "reason" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'reason'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "ReasonServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "serviceRequest";
           fhir:index 1         ]       ]     ], [
       fhir:index 2;
       fhir:StructureMap.group.rule.name [ fhir:value "imagingService" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'imagingService'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "ImagingServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "serviceRequest";
           fhir:index 1         ]       ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.rule.name [ fhir:value "orderDetail" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'orderDetail'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "OrderDetailServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "serviceRequest";
           fhir:index 1         ]       ]     ], [
       fhir:index 4;
       fhir:StructureMap.group.rule.name [ fhir:value "desiredRadiologist" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'desiredRadiologist'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "DesiredRadiologistServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "bundle";
           fhir:index 1         ], [
           fhir:value "serviceRequest";
           fhir:index 2         ]       ]     ], [
       fhir:index 5;
       fhir:StructureMap.group.rule.name [ fhir:value "diagnosisList" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'diagnosisList'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "DiagnosisListServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "patient";
           fhir:index 1         ], [
           fhir:value "bundle";
           fhir:index 2         ], [
           fhir:value "serviceRequest";
           fhir:index 3         ]       ]     ], [
       fhir:index 6;
       fhir:StructureMap.group.rule.name [ fhir:value "Caveat" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'caveat'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "CaveatServiceItems" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "patient";
           fhir:index 1         ], [
           fhir:value "bundle";
           fhir:index 2         ], [
           fhir:value "serviceRequest";
           fhir:index 3         ]       ]     ], [
       fhir:index 7;
       fhir:StructureMap.group.rule.name [ fhir:value "previousResults" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "qr" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "linkId = 'previousResults'" ]       ];
       fhir:StructureMap.group.rule.dependent [
         fhir:index 0;
         fhir:StructureMap.group.rule.dependent.name [ fhir:value "PreviousImagingStudyResults" ];
         fhir:StructureMap.group.rule.dependent.variable [
           fhir:value "grp";
           fhir:index 0         ], [
           fhir:value "bundle";
           fhir:index 1         ], [
           fhir:value "serviceRequest";
           fhir:index 2         ], [
           fhir:value "patient";
           fhir:index 3         ]       ]     ]
  ], [
     fhir:index 2;
     fhir:StructureMap.group.name [ fhir:value "RequestedServiceItems" ];
     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 "BackboneElement" ];
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'requestedService.service') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "requestedService.service" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             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 "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 3;
     fhir:StructureMap.group.name [ fhir:value "ReasonServiceItems" ];
     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 "BackboneElement" ];
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'reason.question') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "reason.question" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "string" ];
             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 "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "reasonCode" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "reasonCode" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "reasonCode" ];
             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 "value" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 4;
     fhir:StructureMap.group.name [ fhir:value "ImagingServiceItems" ];
     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 "BackboneElement" ];
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'imagingService.type') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "requestedService.service" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             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:index 1;
             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.transform [ fhir:value "copy" ];
             fhir:StructureMap.group.rule.target.parameter [
               fhir:index 0;
               fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "coding" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 5;
     fhir:StructureMap.group.name [ fhir:value "OrderDetailServiceItems" ];
     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 "BackboneElement" ];
       fhir:StructureMap.group.input.mode [ fhir:value "source" ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.imagingRegion') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.imagingRegion" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "orderDetail" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "extension" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ext" ]           ], [
             fhir:index 2;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 3;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "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:index 4;
             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://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 5;
             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 "imagingRegion" ]             ]           ], [
             fhir:index 6;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.imagingFocus') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.imagingFocus" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             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 "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ], [
       fhir:index 2;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.laterality') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.laterality" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "orderDetail" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "extension" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ext" ]           ], [
             fhir:index 2;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 3;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "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:index 4;
             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://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 5;
             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 "laterality" ]             ]           ], [
             fhir:index 6;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.viewType') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.viewType" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "orderDetail" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "extension" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ext" ]           ], [
             fhir:index 2;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 3;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "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:index 4;
             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://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 5;
             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 "viewType" ]             ]           ], [
             fhir:index 6;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ], [
       fhir:index 4;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.maneuverType') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.maneuverType" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "orderDetail" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "extension" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ext" ]           ], [
             fhir:index 2;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 3;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "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:index 4;
             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://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 5;
             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 "maneuverType" ]             ]           ], [
             fhir:index 6;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ], [
       fhir:index 5;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'orderDetail.guidanceForAction') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueCoding" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "orderDetail.guidanceForAction" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "Coding" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "coding" ]           ];
           fhir:StructureMap.group.rule.target [
             fhir:index 0;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "orderDetail" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "cc" ]           ], [
             fhir:index 1;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "extension" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "ext" ]           ], [
             fhir:index 2;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "http://fhir.ch/ig/ch-rad-order/StructureDefinition/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 3;
             fhir:StructureMap.group.rule.target.context [ fhir:value "ext" ];
             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 "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:index 4;
             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://fhir.ch/ig/ch-rad-order/CodeSystem/ch-rad-order-order-detail-type" ]             ]           ], [
             fhir:index 5;
             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 "guidanceForAction" ]             ]           ], [
             fhir:index 6;
             fhir:StructureMap.group.rule.target.context [ fhir:value "cc" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "coding" ];
             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 "coding" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 6;
     fhir:StructureMap.group.name [ fhir:value "DesiredRadiologistServiceItems" ];
     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 "BackboneElement" ];
       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:index 2;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "serviceRequest.performer" ];
       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 "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 "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:index 2;
         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 "uuid" ];
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]       ], [
         fhir:index 3;
         fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
         fhir:StructureMap.group.rule.target.element [ fhir:value "performer" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "performer" ]       ], [
         fhir:index 4;
         fhir:StructureMap.group.rule.target.context [ fhir:value "performer" ];
         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 "'urn:uuid:' + 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 "evaluate" ];
         fhir:StructureMap.group.rule.target.parameter [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.parameter.valueString [ fhir:value "'urn:uuid:' + uuid" ]         ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "item" ];
         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 "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'desiredRadiologist.familyName') and answer.exists())" ]         ];
         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 "name" ];
           fhir:StructureMap.group.rule.target.listMode [
             fhir:value "share";
             fhir:index 0           ];
           fhir:StructureMap.group.rule.target.listRuleId [ fhir:value "name" ]         ], [
           fhir:index 1;
           fhir:StructureMap.group.rule.target.context [ fhir:value "name" ];
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
           fhir:StructureMap.group.rule.target.element [ fhir:value "family" ];
           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 "item.answer.value" ]           ]         ]       ], [
         fhir:index 1;
         fhir:StructureMap.group.rule.name [ fhir:value "item" ];
         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 "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'desiredRadiologist.givenName') and answer.exists())" ]         ];
         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 "name" ];
           fhir:StructureMap.group.rule.target.listMode [
             fhir:value "share";
             fhir:index 0           ];
           fhir:StructureMap.group.rule.target.listRuleId [ fhir:value "name" ]         ], [
           fhir:index 1;
           fhir:StructureMap.group.rule.target.context [ fhir:value "name" ];
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
           fhir:StructureMap.group.rule.target.element [ fhir:value "given" ];
           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 "item.answer.value" ]           ]         ]       ]     ]
  ], [
     fhir:index 7;
     fhir:StructureMap.group.name [ fhir:value "DiagnosisListServiceItems" ];
     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 "BackboneElement" ];
       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 "bundle" ];
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'diagnosisList.secondaryDiagnosis') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "diagnosisList.secondaryDiagnosis" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "string" ];
             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 "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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "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 "value" ]             ]           ], [
             fhir:index 13;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 8;
     fhir:StructureMap.group.name [ fhir:value "CaveatServiceItems" ];
     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 "BackboneElement" ];
       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 "bundle" ];
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.rule [
       fhir:index 0;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.bloodCoagulation') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.bloodCoagulation" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "64779008" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Blood coagulation disorder (disorder)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 1;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.renalInsufficiency') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.renalInsufficiency" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "723188008" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Renal insufficiency (disorder)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ];
           fhir:StructureMap.group.rule.rule [
             fhir:index 0;
             fhir:StructureMap.group.rule.name [ fhir:value "RenalInsufficiencyCreatinineServiceItems" ];
             fhir:StructureMap.group.rule.source [
               fhir:index 0;
               fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
               fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
               fhir:StructureMap.group.rule.source.variable [ fhir:value "item2" ];
               fhir:StructureMap.group.rule.source.condition [ fhir:value "(linkId.value = 'caveat.renalInsufficiency.creatinine')" ]             ];
             fhir:StructureMap.group.rule.dependent [
               fhir:index 0;
               fhir:StructureMap.group.rule.dependent.name [ fhir:value "RenalInsufficiencyCreatinineServiceItems" ];
               fhir:StructureMap.group.rule.dependent.variable [
                 fhir:value "item2";
                 fhir:index 0               ], [
                 fhir:value "patient";
                 fhir:index 1               ], [
                 fhir:value "bundle";
                 fhir:index 2               ], [
                 fhir:value "serviceRequest";
                 fhir:index 3               ], [
                 fhir:value "condition";
                 fhir:index 4               ]             ];
             fhir:StructureMap.group.rule.documentation [ fhir:value "FIXME TODO answer.item as item2 where (linkId.value = 'caveat.renalInsufficiency.creatinineClearance') then RenalInsufficiencyCreatinineServiceItems(item2, patient, bundle, serviceRequest, condition) \"RenalInsufficiencyCreatinineServiceItems\";" ]           ]         ]       ]     ], [
       fhir:index 2;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.claustrophobia') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.claustrophobia" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "19887002" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Claustrophobia (finding)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.bodyPiercing') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.bodyPiercing" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "879862001" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Body piercing (finding)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 4;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.device') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.device" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "string" ];
             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 "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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "397578001" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Device in situ (finding)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ], [
             fhir:index 18;
             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 "note" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]           ], [
             fhir:index 19;
             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 "value" ]             ]           ]         ]       ]     ], [
       fhir:index 5;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.hyperthyroidism') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.hyperthyroidism" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "34486009" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Hyperthyroidism (disorder)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 6;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.diabetes') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.diabetes" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "73211009" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Diabetes mellitus (disorder)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 7;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.gravida') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.gravida" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "366321006" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Finding of gravida (finding)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 8;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.contrastMediaAllergy') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.contrastMediaAllergy" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "boolean" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "value" ];
             fhir:StructureMap.group.rule.source.condition [ fhir:value "answer.valueBoolean" ]           ];
           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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "293637006" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Allergy to contrast media (finding)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ]         ]       ]     ], [
       fhir:index 9;
       fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
       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 "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.drugPrescription') and answer.exists())" ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "answer.valueString" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "caveat.drugPrescription" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.type [ fhir:value "string" ];
             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 "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 "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 2;
             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 "uuid" ];
             fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]           ], [
             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 "fullUrl" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 4;
             fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
             fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
             fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]           ], [
             fhir:index 5;
             fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
             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 "'urn:uuid:' + uuid" ]             ]           ], [
             fhir:index 6;
             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 "category" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "category" ]           ], [
             fhir:index 7;
             fhir:StructureMap.group.rule.target.context [ fhir:value "category" ];
             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:index 8;
             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 "problem-list-item" ]             ]           ], [
             fhir:index 9;
             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-category" ]             ]           ], [
             fhir:index 10;
             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.valueString [ fhir:value "Problem List Item" ]             ]           ], [
             fhir:index 11;
             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 "code" ]           ], [
             fhir:index 12;
             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 "coding2" ]           ], [
             fhir:index 13;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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 "182817000" ]             ]           ], [
             fhir:index 14;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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://snomed.info/sct" ]             ]           ], [
             fhir:index 15;
             fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
             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.valueString [ fhir:value "Drug prescription (situation)" ]             ]           ], [
             fhir:index 16;
             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 "subject" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]           ], [
             fhir:index 17;
             fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
             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 "'urn:uuid:' + patient.id" ]             ]           ], [
             fhir:index 18;
             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 "note" ];
             fhir:StructureMap.group.rule.target.variable [ fhir:value "note" ]           ], [
             fhir:index 19;
             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 "value" ]             ]           ]         ]       ]     ]
  ], [
     fhir:index 9;
     fhir:StructureMap.group.name [ fhir:value "RenalInsufficiencyCreatinineServiceItems" ];
     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 "BackboneElement" ];
       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 "bundle" ];
       fhir:StructureMap.group.input.type [ fhir:value "Bundle" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 3;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 4;
       fhir:StructureMap.group.input.name [ fhir:value "condition" ];
       fhir:StructureMap.group.input.type [ fhir:value "Condition" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ];
     fhir:StructureMap.group.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 "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 "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 "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 2;
         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 "uuid" ];
         fhir:StructureMap.group.rule.target.transform [ fhir:value "uuid" ]       ], [
         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 "fullUrl" ];
         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 "'urn:uuid:' + uuid" ]         ]       ], [
         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 "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.target.context [ fhir:value "observation" ];
         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:index 6;
         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 "coding2" ]       ], [
         fhir:index 7;
         fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
         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 "723188008" ]         ]       ], [
         fhir:index 8;
         fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
         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://snomed.info/sct" ]         ]       ], [
         fhir:index 9;
         fhir:StructureMap.group.rule.target.context [ fhir:value "coding2" ];
         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.valueString [ fhir:value "Renal insufficiency (disorder)" ]         ]       ], [
         fhir:index 10;
         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 "evidence" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "evidence" ]       ], [
         fhir:index 11;
         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 "detail" ]       ], [
         fhir:index 12;
         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 "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 "'urn:uuid:' + uuid" ]         ]       ], [
         fhir:index 13;
         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 "subject" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "subject" ]       ], [
         fhir:index 14;
         fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
         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 "'urn:uuid:' + patient.id" ]         ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "caveat.renalInsufficiency.creatinine.quantity" ];
         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 "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.renalInsufficiency.creatinine.quantity') and answer.exists())" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]           ];
           fhir:StructureMap.group.rule.rule [
             fhir:index 0;
             fhir:StructureMap.group.rule.name [ fhir:value "value-Quantity" ];
             fhir:StructureMap.group.rule.source [
               fhir:index 0;
               fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
               fhir:StructureMap.group.rule.source.type [ fhir:value "Quantity" ];
               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 "observation" ];
               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 "caveat.renalInsufficiency.creatinine.dateTime" ];
         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 "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'caveat.renalInsufficiency.creatinine.dateTime') and answer.exists())" ]         ];
         fhir:StructureMap.group.rule.rule [
           fhir:index 0;
           fhir:StructureMap.group.rule.name [ fhir:value "item.answer" ];
           fhir:StructureMap.group.rule.source [
             fhir:index 0;
             fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
             fhir:StructureMap.group.rule.source.element [ fhir:value "answer" ];
             fhir:StructureMap.group.rule.source.variable [ fhir:value "answer" ]           ];
           fhir:StructureMap.group.rule.rule [
             fhir:index 0;
             fhir:StructureMap.group.rule.name [ fhir:value "value-dateTime" ];
             fhir:StructureMap.group.rule.source [
               fhir:index 0;
               fhir:StructureMap.group.rule.source.context [ fhir:value "answer" ];
               fhir:StructureMap.group.rule.source.type [ fhir:value "dateTime" ];
               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 "observation" ];
               fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
               fhir:StructureMap.group.rule.target.element [ fhir:value "effective" ];
               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 10;
     fhir:StructureMap.group.name [ fhir:value "PreviousImagingStudyResults" ];
     fhir:StructureMap.group.typeMode [ fhir:value "none" ];
     fhir:StructureMap.group.input [
       fhir:index 0;
       fhir:StructureMap.group.input.name [ fhir:value "grp" ];
       fhir:StructureMap.group.input.type [ fhir:value "BackboneElement" ];
       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:index 2;
       fhir:StructureMap.group.input.name [ fhir:value "serviceRequest" ];
       fhir:StructureMap.group.input.type [ fhir:value "ServiceRequest" ];
       fhir:StructureMap.group.input.mode [ fhir:value "target" ]     ], [
       fhir:index 3;
       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 "imagingStudy" ];
       fhir:StructureMap.group.rule.source [
         fhir:index 0;
         fhir:StructureMap.group.rule.source.context [ fhir:value "grp" ];
         fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.variable [ fhir:value "item" ];
         fhir:StructureMap.group.rule.source.condition [ fhir:value "(linkId.value = 'previousResults.imagingStudy')" ]       ];
       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 "resource" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "imagingStudy" ];
         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 "ImagingStudy" ]         ]       ], [
         fhir:index 2;
         fhir:StructureMap.group.rule.target.context [ fhir:value "imagingStudy" ];
         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 "uuid" ]       ], [
         fhir:index 3;
         fhir:StructureMap.group.rule.target.context [ fhir:value "imagingStudy" ];
         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 "available" ]         ]       ], [
         fhir:index 4;
         fhir:StructureMap.group.rule.target.context [ fhir:value "imagingStudy" ];
         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 "subject" ]       ], [
         fhir:index 5;
         fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
         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 "'urn:uuid:' + patient.id" ]         ]       ], [
         fhir:index 6;
         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 "urn:uuid:" ]         ], [
           fhir:index 1;
           fhir:StructureMap.group.rule.target.parameter.valueId [ fhir:value "uuid" ]         ]       ], [
         fhir:index 7;
         fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
         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 "subject" ]       ], [
         fhir:index 8;
         fhir:StructureMap.group.rule.target.context [ fhir:value "subject" ];
         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 "'urn:uuid:' + patient.id" ]         ]       ], [
         fhir:index 9;
         fhir:StructureMap.group.rule.target.context [ fhir:value "serviceRequest" ];
         fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
         fhir:StructureMap.group.rule.target.element [ fhir:value "supportingInfo" ];
         fhir:StructureMap.group.rule.target.variable [ fhir:value "supportingInfo" ]       ], [
         fhir:index 10;
         fhir:StructureMap.group.rule.target.context [ fhir:value "supportingInfo" ];
         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 "'urn:uuid:' + uuid" ]         ]       ];
       fhir:StructureMap.group.rule.rule [
         fhir:index 0;
         fhir:StructureMap.group.rule.name [ fhir:value "uid" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "dictomitem" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'previousResults.imagingStudy.uid') and answer.exists())" ]         ];
         fhir:StructureMap.group.rule.target [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.context [ fhir:value "imagingStudy" ];
           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 "uid" ]         ], [
           fhir:index 1;
           fhir:StructureMap.group.rule.target.context [ fhir:value "uid" ];
           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 "urn:dicom:uid" ]           ]         ], [
           fhir:index 2;
           fhir:StructureMap.group.rule.target.context [ fhir:value "uid" ];
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
           fhir:StructureMap.group.rule.target.element [ fhir:value "use" ];
           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 "official" ]           ]         ], [
           fhir:index 3;
           fhir:StructureMap.group.rule.target.context [ fhir:value "uid" ];
           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 "'urn:oid:' + dictomitem.answer.value" ]           ]         ]       ], [
         fhir:index 1;
         fhir:StructureMap.group.rule.name [ fhir:value "acsn" ];
         fhir:StructureMap.group.rule.source [
           fhir:index 0;
           fhir:StructureMap.group.rule.source.context [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.element [ fhir:value "item" ];
           fhir:StructureMap.group.rule.source.variable [ fhir:value "dictomitem" ];
           fhir:StructureMap.group.rule.source.condition [ fhir:value "((linkId.value = 'previousResults.imagingStudy.acsn') and answer.exists())" ]         ];
         fhir:StructureMap.group.rule.target [
           fhir:index 0;
           fhir:StructureMap.group.rule.target.context [ fhir:value "imagingStudy" ];
           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 "acsn" ]         ], [
           fhir:index 1;
           fhir:StructureMap.group.rule.target.context [ fhir:value "acsn" ];
           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:index 2;
           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 "coding" ];
           fhir:StructureMap.group.rule.target.variable [ fhir:value "coding" ]         ], [
           fhir:index 3;
           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/v2-0203" ]           ]         ], [
           fhir:index 4;
           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 "ACSN" ]           ]         ], [
           fhir:index 5;
           fhir:StructureMap.group.rule.target.context [ fhir:value "acsn" ];
           fhir:StructureMap.group.rule.target.contextType [ fhir:value "variable" ];
           fhir:StructureMap.group.rule.target.element [ fhir:value "use" ];
           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 "usual" ]           ]         ], [
           fhir:index 6;
           fhir:StructureMap.group.rule.target.context [ fhir:value "acsn" ];
           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 "dictomitem.answer.value" ]           ]         ]       ]     ]
  ].

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

 a owl:Ontology;
  owl:imports fhir:fhir.ttl.