BundleToCda
type: StructureMap
node role: treeRoot
resource.id:
  value: BundleToCda
resource.meta:
  meta.version id:
    value: 3
  meta.last updated:
    value: 2022-01-11T22:14:50.980+01:00
domain resource.text:
  narrative.status:
    value: generated
  narrative.div: map "http://fhir.ch/ig/cda-fhir-maps/StructureMap/BundleToCda" = "BundleToCda" // CDA document // 2020-01-16 Oliver Egger, copyright ahdis ag, Apache License // CDA: http://build.fhir.org/ig/ahdis/cda-core-2.0/branches/master/index.html // FHIR: http://hl7.org/fhir/r4/ uses "http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument" alias ClinicalDocument as target uses "http://hl7.org/fhir/cda/StructureDefinition/Author" alias Author as target uses "http://hl7.org/fhir/cda/StructureDefinition/RecordTarget" alias RecordTarget as target uses "http://hl7.org/fhir/cda/StructureDefinition/Custodian" alias Custodian as target uses "http://hl7.org/fhir/cda/StructureDefinition/Organization" alias CdaOrganization as target uses "http://hl7.org/fhir/cda/StructureDefinition/LegalAuthenticator" alias LegalAuthenticator as target uses "http://hl7.org/fhir/cda/StructureDefinition/Section" alias CdaSection as target uses "http://hl7.org/fhir/StructureDefinition/Bundle" alias Bundle as source uses "http://hl7.org/fhir/StructureDefinition/Composition" alias Composition as source uses "http://hl7.org/fhir/StructureDefinition/Practitioner" alias Practitioner as source uses "http://hl7.org/fhir/StructureDefinition/Patient" alias Patient as source uses "http://hl7.org/fhir/StructureDefinition/Organization" alias Organization as source uses "http://hl7.org/fhir/StructureDefinition/BackboneElement" alias BackboneElement as source imports "http://fhir.ch/ig/cda-fhir-maps/StructureMap/FhirToCdaTypes" group BundleToCda(source bundle : Bundle, target cda : ClinicalDocument) { bundle -> cda.recordTarget as recordTarget, cda.author as author then BundleToClinicalDocument(bundle, recordTarget, author, cda) "bundle"; } group BundleToClinicalDocument(source bundle : Bundle, target recordTarget : RecordTarget, target author : Author, target cda : ClinicalDocument) { bundle -> cda.typeId as typeId then { bundle -> typeId.root = '2.16.840.1.113883.1.3' "root"; bundle -> typeId.extension = 'POCD_H…
structure map.url:
  value: http://fhir.ch/ig/cda-fhir-maps/StructureMap/BundleToCda
structure map.version:
  value: 0.3.0
structure map.name:
  value: BundleToCda
structure map.status:
  value: draft
structure map.date:
  value: 2022-02-11T11:14:39+01:00
structure map.publisher:
  value: ahdis
structure map.contact:
  index: 0
  contact detail.name:
    value: ahdis
  contact detail.telecom:
    index: 0
    contact point.system:
      value: url
    contact point.value:
      value: http://www.ahdis.ch/
structure map.description:
  value: CDA document 2020-01-16 Oliver Egger, copyright ahdis ag, Apache License CDA: http://build.fhir.org/ig/ahdis/cda-core-2.0/branches/master/index.html FHIR: http://hl7.org/fhir/r4/
structure map.copyright:
  value: CC-BY-SA-4.0
structure map.structure:
  index: 0
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument
    link: http://hl7.org/fhir/cda/StructureDefinition/ClinicalDocument
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: ClinicalDocument
structure map.structure:
  index: 1
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/Author
    link: http://hl7.org/fhir/cda/StructureDefinition/Author
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: Author
structure map.structure:
  index: 2
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/RecordTarget
    link: http://hl7.org/fhir/cda/StructureDefinition/RecordTarget
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: RecordTarget
structure map.structure:
  index: 3
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/Custodian
    link: http://hl7.org/fhir/cda/StructureDefinition/Custodian
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: Custodian
structure map.structure:
  index: 4
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/Organization
    link: http://hl7.org/fhir/cda/StructureDefinition/Organization
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: CdaOrganization
structure map.structure:
  index: 5
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/LegalAuthenticator
    link: http://hl7.org/fhir/cda/StructureDefinition/LegalAuthenticator
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: LegalAuthenticator
structure map.structure:
  index: 6
  structure map.structure.url:
    value: http://hl7.org/fhir/cda/StructureDefinition/Section
    link: http://hl7.org/fhir/cda/StructureDefinition/Section
  structure map.structure.mode:
    value: target
  structure map.structure.alias:
    value: CdaSection
structure map.structure:
  index: 7
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/Bundle
    link: http://hl7.org/fhir/StructureDefinition/Bundle
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: Bundle
structure map.structure:
  index: 8
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/Composition
    link: http://hl7.org/fhir/StructureDefinition/Composition
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: Composition
structure map.structure:
  index: 9
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/Practitioner
    link: http://hl7.org/fhir/StructureDefinition/Practitioner
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: Practitioner
structure map.structure:
  index: 10
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/Patient
    link: http://hl7.org/fhir/StructureDefinition/Patient
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: Patient
structure map.structure:
  index: 11
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/Organization
    link: http://hl7.org/fhir/StructureDefinition/Organization
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: Organization
structure map.structure:
  index: 12
  structure map.structure.url:
    value: http://hl7.org/fhir/StructureDefinition/BackboneElement
    link: http://hl7.org/fhir/StructureDefinition/BackboneElement
  structure map.structure.mode:
    value: source
  structure map.structure.alias:
    value: BackboneElement
structure map.import:
  value: http://fhir.ch/ig/cda-fhir-maps/StructureMap/FhirToCdaTypes
  index: 0
  link: http://fhir.ch/ig/cda-fhir-maps/StructureMap/FhirToCdaTypes
structure map.group:
  index: 0
  structure map.group.name:
    value: BundleToCda
  structure map.group.type mode:
    value: none
  structure map.group.input:
    index: 0
    structure map.group.input.name:
      value: bundle
    structure map.group.input.type:
      value: Bundle
    structure map.group.input.mode:
      value: source
  structure map.group.input:
    index: 1
    structure map.group.input.name:
      value: cda
    structure map.group.input.type:
      value: ClinicalDocument
    structure map.group.input.mode:
      value: target
  structure map.group.rule:
    index: 0
    structure map.group.rule.name:
      value: bundle
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: bundle
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cda
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: recordTarget
      structure map.group.rule.target.variable:
        value: recordTarget
    structure map.group.rule.target:
      index: 1
      structure map.group.rule.target.context:
        value: cda

value: variable

value: author

value: author

index: 0
structure map.group.rule.dependent.name:
  value: BundleToClinicalDocument
structure map.group.rule.dependent.variable:
  value: bundle
  index: 0
structure map.group.rule.dependent.variable:
  value: recordTarget
  index: 1
structure map.group.rule.dependent.variable:
  value: author
  index: 2
structure map.group.rule.dependent.variable:
  value: cda
  index: 3

index: 1
structure map.group.name:
  value: BundleToClinicalDocument
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: recordTarget
  structure map.group.input.type:
    value: RecordTarget
  structure map.group.input.mode:
    value: target
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: author
  structure map.group.input.type:
    value: Author
  structure map.group.input.mode:
    value: target
structure map.group.input:
  index: 3
  structure map.group.input.name:
    value: cda
  structure map.group.input.type:
    value: ClinicalDocument
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: typeId
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: typeId
    structure map.group.rule.target.variable:
      value: typeId
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: root
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: bundle
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: typeId
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: root
      structure map.group.rule.target.transform:
        value: copy
      structure map.group.rule.target.parameter:
        index: 0
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: extension
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: bundle
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: typeId
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: extension
      structure map.group.rule.target.transform:
        value: copy
      structure map.group.rule.target.parameter:
        index: 0
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: id
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
    structure map.group.rule.source.element:
      value: identifier
    structure map.group.rule.source.variable:
      value: identifier
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: id
    structure map.group.rule.target.variable:
      value: id
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: IdentifierII
    structure map.group.rule.dependent.variable:
      value: identifier
      index: 0
    structure map.group.rule.dependent.variable:
      value: id
      index: 1
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: effectiveTime
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
    structure map.group.rule.source.element:
      value: timestamp
    structure map.group.rule.source.variable:
      value: timestamp
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: effectiveTime
    structure map.group.rule.target.variable:
      value: effectiveTime
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: InstantTS
    structure map.group.rule.dependent.variable:
      value: timestamp
      index: 0
    structure map.group.rule.dependent.variable:
      value: effectiveTime
      index: 1
structure map.group.rule:
  index: 3
  structure map.group.rule.name:
    value: entry
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
    structure map.group.rule.source.element:
      value: entry
    structure map.group.rule.source.variable:
      value: entry
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: resource
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: resource
      structure map.group.rule.source.condition:
        value: $this.ofType(FHIR.Composition)
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: CompositionClinicalDocument
      structure map.group.rule.dependent.variable:
        value: bundle
        index: 0
      structure map.group.rule.dependent.variable:
        value: resource
        index: 1
      structure map.group.rule.dependent.variable:
        value: recordTarget
        index: 2
      structure map.group.rule.dependent.variable:
        value: author
        index: 3
      structure map.group.rule.dependent.variable:
        value: cda
        index: 4

value: 2.16.840.1.113883.1.3

value: POCD_HD000040

index: 2
structure map.group.name:
  value: SectionCdaSection
structure map.group.type mode:
  value: none
structure map.group.documentation:
  value: _________________________ Section Level Templates _________________________
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: section
  structure map.group.input.type:
    value: BackboneElement
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: cdasection
  structure map.group.input.type:
    value: CdaSection
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: valueIdentifier
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
    structure map.group.rule.source.element:
      value: extension
    structure map.group.rule.source.variable:
      value: extension
    structure map.group.rule.source.condition:
      value: $this.url = 'http://fhir.ch/ig/ch-core/StructureDefinition/ch-ext-epr-sectionid'
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cdasection
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: id
    structure map.group.rule.target.variable:
      value: id
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: IdentifierII
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: extension
      structure map.group.rule.source.element:
        value: valueIdentifier
      structure map.group.rule.source.variable:
        value: valueIdentifier
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: IdentifierII
      structure map.group.rule.dependent.variable:
        value: valueIdentifier
        index: 0
      structure map.group.rule.dependent.variable:
        value: id
        index: 1
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: sectionid
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
    structure map.group.rule.source.variable:
      value: section
    structure map.group.rule.source.condition:
      value: $this.extension.where(url = 'http://fhir.ch/ig/ch-core/StructureDefinition/ch-ext-epr-sectionid').exists() = false
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cdasection
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: id
    structure map.group.rule.target.variable:
      value: id
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: setId
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: bundle
      structure map.group.rule.source.element:
        value: identifier
      structure map.group.rule.source.variable:
        value: identifier
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cdasection
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: id
      structure map.group.rule.target.variable:
        value: id
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: IdentifierII
      structure map.group.rule.dependent.variable:
        value: identifier
        index: 0
      structure map.group.rule.dependent.variable:
        value: id
        index: 1
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: code
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
    structure map.group.rule.source.element:
      value: code
    structure map.group.rule.source.variable:
      value: code
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: codingsection
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: code
      structure map.group.rule.source.element:
        value: coding
      structure map.group.rule.source.variable:
        value: coding
      structure map.group.rule.source.condition:
        value: $this.system = 'http://loinc.org'
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cdasection
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: code
      structure map.group.rule.target.variable:
        value: cdacode
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: CodingCE
      structure map.group.rule.dependent.variable:
        value: coding
        index: 0
      structure map.group.rule.dependent.variable:
        value: cdacode
        index: 1
structure map.group.rule:
  index: 3
  structure map.group.rule.name:
    value: title
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
    structure map.group.rule.source.element:
      value: title
    structure map.group.rule.source.variable:
      value: title
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cdasection
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: title
    structure map.group.rule.target.variable:
      value: cdatitle
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: cdatitle

value: variable

value: data

value: copy

index: 0
structure map.group.rule.target.parameter.value id:
  value: title

index: 4
structure map.group.rule.name:
  value: text
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: section
  structure map.group.rule.source.element:
    value: text
  structure map.group.rule.source.variable:
    value: text
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: div
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: text
    structure map.group.rule.source.element:
      value: div
    structure map.group.rule.source.variable:
      value: div
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cdasection
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: text
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value id:
        value: div

index: 3
structure map.group.name:
  value: CompositionClinicalDocument
structure map.group.type mode:
  value: none
structure map.group.documentation:
  value: _________________________ Entry Level Templates ________________________ _________________________ Header Level Templates _________________________
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: composition
  structure map.group.input.type:
    value: Composition
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: recordTarget
  structure map.group.input.type:
    value: RecordTarget
  structure map.group.input.mode:
    value: target
structure map.group.input:
  index: 3
  structure map.group.input.name:
    value: author
  structure map.group.input.type:
    value: Author
  structure map.group.input.mode:
    value: target
structure map.group.input:
  index: 4
  structure map.group.input.name:
    value: cda
  structure map.group.input.type:
    value: ClinicalDocument
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: type
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: composition
    structure map.group.rule.source.element:
      value: type
    structure map.group.rule.source.variable:
      value: type
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: code
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: type
      structure map.group.rule.source.element:
        value: coding
      structure map.group.rule.source.variable:
        value: coding
      structure map.group.rule.source.condition:
        value: $this.system = 'http://loinc.org'
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cda
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: code
      structure map.group.rule.target.variable:
        value: code
      structure map.group.rule.target.list mode:
        value: share
        index: 0
      structure map.group.rule.target.list rule id:
        value: docCode
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: CodingCE
      structure map.group.rule.dependent.variable:
        value: coding
        index: 0
      structure map.group.rule.dependent.variable:
        value: code
        index: 1
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: title
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: composition
    structure map.group.rule.source.element:
      value: title
    structure map.group.rule.source.variable:
      value: title
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: title
    structure map.group.rule.target.variable:
      value: t
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: titleInner
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: title
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: t
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: data
      structure map.group.rule.target.transform:
        value: copy
      structure map.group.rule.target.parameter:
        index: 0
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: confidentialityCode
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: composition
    structure map.group.rule.source.element:
      value: confidentiality
    structure map.group.rule.source.variable:
      value: conf
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: confidentialityCode
    structure map.group.rule.target.variable:
      value: cdaconf
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: conf
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: conf
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cdaconf
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: code
      structure map.group.rule.target.transform:
        value: copy
      structure map.group.rule.target.parameter:
        index: 0
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: codeSystem
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: conf
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cdaconf
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: codeSystem
      structure map.group.rule.target.transform:
        value: copy
      structure map.group.rule.target.parameter:
        index: 0

value: title

value: conf

value: 2.16.840.1.113883.5.25

index: 3
structure map.group.rule.name:
  value: languageCode
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: composition
  structure map.group.rule.source.element:
    value: language
  structure map.group.rule.source.variable:
    value: language
structure map.group.rule.target:
  index: 0
  structure map.group.rule.target.context:
    value: cda
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: languageCode
  structure map.group.rule.target.variable:
    value: languageCode
structure map.group.rule.target:
  index: 1
  structure map.group.rule.target.context:
    value: languageCode
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: code
  structure map.group.rule.target.transform:
    value: copy
  structure map.group.rule.target.parameter:
    index: 0
    structure map.group.rule.target.parameter.value id:
      value: language

index: 4
structure map.group.rule.name:
  value: patient
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: bundle
  structure map.group.rule.source.element:
    value: entry
  structure map.group.rule.source.variable:
    value: entry
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: uuid
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: fullUrl
    structure map.group.rule.source.condition:
      value: ($this in %composition.subject.reference) and $this.startsWith('urn:uuid')
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: patient
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.type:
        value: Patient
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: patient
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: PatientRecordTarget
      structure map.group.rule.dependent.variable:
        value: patient
        index: 0
      structure map.group.rule.dependent.variable:
        value: bundle
        index: 1
      structure map.group.rule.dependent.variable:
        value: recordTarget
        index: 2
structure map.group.rule.rule:
  index: 1
  structure map.group.rule.name:
    value: patient
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: resource
    structure map.group.rule.source.variable:
      value: patient
    structure map.group.rule.source.condition:
      value: ('Patient' + '/' + $this.id) in %composition.subject.reference
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: PatientRecordTarget
    structure map.group.rule.dependent.variable:
      value: patient
      index: 0
    structure map.group.rule.dependent.variable:
      value: bundle
      index: 1
    structure map.group.rule.dependent.variable:
      value: recordTarget
      index: 2
structure map.group.rule.rule:
  index: 2
  structure map.group.rule.name:
    value: uuid
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: fullUrl
    structure map.group.rule.source.condition:
      value: ($this in %composition.custodian.reference) and $this.startsWith('urn:uuid')
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: custodian
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.type:
        value: Organization
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: organization
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: cda
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: custodian
      structure map.group.rule.target.variable:
        value: custodian
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: OrganizationCustodian
      structure map.group.rule.dependent.variable:
        value: organization
        index: 0
      structure map.group.rule.dependent.variable:
        value: custodian
        index: 1
structure map.group.rule.rule:
  index: 3
  structure map.group.rule.name:
    value: custodian
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: resource
    structure map.group.rule.source.variable:
      value: organization
    structure map.group.rule.source.condition:
      value: ('Organization' + '/' + $this.id) in %composition.custodian.reference
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: custodian
    structure map.group.rule.target.variable:
      value: custodian
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: OrganizationCustodian
    structure map.group.rule.dependent.variable:
      value: organization
      index: 0
    structure map.group.rule.dependent.variable:
      value: custodian
      index: 1
structure map.group.rule.rule:
  index: 4
  structure map.group.rule.name:
    value: uuid
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: fullUrl
    structure map.group.rule.source.condition:
      value: ($this in %composition.author.reference) and $this.startsWith('urn:uuid')
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: author
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.type:
        value: Practitioner
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: practitioner
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: PractitionerAuthor
      structure map.group.rule.dependent.variable:
        value: bundle
        index: 0
      structure map.group.rule.dependent.variable:
        value: composition
        index: 1
      structure map.group.rule.dependent.variable:
        value: practitioner
        index: 2
      structure map.group.rule.dependent.variable:
        value: author
        index: 3
structure map.group.rule.rule:
  index: 5

value: author

index: 0
structure map.group.rule.source.context:
  value: entry
structure map.group.rule.source.element:
  value: resource
structure map.group.rule.source.variable:
  value: practitioner
structure map.group.rule.source.condition:
  value: ('Practitioner' + '/' + $this.id) in %composition.author.reference

index: 0
structure map.group.rule.dependent.name:
  value: PractitionerAuthor
structure map.group.rule.dependent.variable:
  value: bundle
  index: 0
structure map.group.rule.dependent.variable:
  value: composition
  index: 1
structure map.group.rule.dependent.variable:
  value: practitioner
  index: 2
structure map.group.rule.dependent.variable:
  value: author
  index: 3

index: 6
structure map.group.rule.name:
  value: uuid
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: entry
  structure map.group.rule.source.element:
    value: fullUrl
  structure map.group.rule.source.condition:
    value: ($this in %composition.attester.party.reference) and $this.startsWith('urn:uuid')
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: legalAuthenticator
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.type:
      value: Practitioner
    structure map.group.rule.source.element:
      value: resource
    structure map.group.rule.source.variable:
      value: practitioner
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: cda
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: legalAuthenticator
    structure map.group.rule.target.variable:
      value: legalAuthenticator
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: PractitionerLegalAuthenticator
    structure map.group.rule.dependent.variable:
      value: bundle
      index: 0
    structure map.group.rule.dependent.variable:
      value: composition
      index: 1
    structure map.group.rule.dependent.variable:
      value: practitioner
      index: 2
    structure map.group.rule.dependent.variable:
      value: legalAuthenticator
      index: 3

index: 7
structure map.group.rule.name:
  value: legalAuthenticator
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: entry
  structure map.group.rule.source.element:
    value: resource
  structure map.group.rule.source.variable:
    value: practitioner
  structure map.group.rule.source.condition:
    value: ('Practitioner' + '/' + $this.id) in %composition.attester.party.reference
structure map.group.rule.target:
  index: 0
  structure map.group.rule.target.context:
    value: cda
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: legalAuthenticator
  structure map.group.rule.target.variable:
    value: legalAuthenticator
structure map.group.rule.dependent:
  index: 0
  structure map.group.rule.dependent.name:
    value: PractitionerLegalAuthenticator
  structure map.group.rule.dependent.variable:
    value: bundle
    index: 0
  structure map.group.rule.dependent.variable:
    value: composition
    index: 1
  structure map.group.rule.dependent.variable:
    value: practitioner
    index: 2
  structure map.group.rule.dependent.variable:
    value: legalAuthenticator
    index: 3

index: 5
structure map.group.rule.name:
  value: section
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: composition
  structure map.group.rule.source.element:
    value: section
  structure map.group.rule.source.variable:
    value: section
  structure map.group.rule.source.condition:
    value: $this.code.exists() = false
structure map.group.rule.target:
  index: 0
  structure map.group.rule.target.context:
    value: cda
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: component
  structure map.group.rule.target.variable:
    value: component
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: contextConductionInd
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: component
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: contextConductionInd
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value boolean:
        value: true
structure map.group.rule.rule:
  index: 1
  structure map.group.rule.name:
    value: cdasection
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: section
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: component
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: structuredBody
    structure map.group.rule.target.variable:
      value: structuredBody
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: structuredBody
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: component
    structure map.group.rule.target.variable:
      value: component
  structure map.group.rule.target:
    index: 2
    structure map.group.rule.target.context:
      value: component
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: section
    structure map.group.rule.target.variable:
      value: cdasection
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: SectionCdaSection
    structure map.group.rule.dependent.variable:
      value: bundle
      index: 0
    structure map.group.rule.dependent.variable:
      value: section
      index: 1
    structure map.group.rule.dependent.variable:
      value: cdasection
      index: 2
structure map.group.rule.documentation:
  value: source.date -> tgt.effectiveTime "effectiveTime";

index: 4
structure map.group.name:
  value: PatientRecordTarget
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Patient
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: RecordTarget
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: patientRole
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: patientRole
    structure map.group.rule.target.variable:
      value: patientRole
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: identifier
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: identifier
      structure map.group.rule.source.variable:
        value: identifier
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: id
      structure map.group.rule.target.variable:
        value: id
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: IdentifierII
      structure map.group.rule.dependent.variable:
        value: identifier
        index: 0
      structure map.group.rule.dependent.variable:
        value: id
        index: 1
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: address
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: address
      structure map.group.rule.source.variable:
        value: address
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: addr
      structure map.group.rule.target.variable:
        value: ad
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: AddressAD
      structure map.group.rule.dependent.variable:
        value: address
        index: 0
      structure map.group.rule.dependent.variable:
        value: ad
        index: 1
  structure map.group.rule.rule:
    index: 2
    structure map.group.rule.name:
      value: patient
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: patient
      structure map.group.rule.target.variable:
        value: patient
    structure map.group.rule.rule:
      index: 0
      structure map.group.rule.name:
        value: name
      structure map.group.rule.source:
        index: 0
      structure map.group.rule.target:
        index: 0
      structure map.group.rule.dependent:
        index: 0
    structure map.group.rule.rule:
      index: 1
      structure map.group.rule.name:
        value: birthDate
      structure map.group.rule.source:
        index: 0
      structure map.group.rule.target:
        index: 0
      structure map.group.rule.dependent:
        index: 0
    structure map.group.rule.rule:
      index: 2
      structure map.group.rule.name:
        value: gender
      structure map.group.rule.source:
        index: 0
      structure map.group.rule.target:
        index: 0
      structure map.group.rule.rule:
        index: 0
      structure map.group.rule.rule:
        index: 1
      structure map.group.rule.rule:
        index: 2
      structure map.group.rule.rule:
        index: 3
      structure map.group.rule.rule:
        index: 4
      structure map.group.rule.rule:
        index: 5
  structure map.group.rule.rule:
    index: 3
    structure map.group.rule.name:
      value: telecom
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: telecom
      structure map.group.rule.source.variable:
        value: telecom
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: telecom
      structure map.group.rule.target.variable:
        value: tel
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: ContactPointTEL
      structure map.group.rule.dependent.variable:
        value: telecom
        index: 0
      structure map.group.rule.dependent.variable:
        value: tel
        index: 1

value: src

value: name

value: humanname

value: patient

value: variable

value: name

value: en

value: HumanNameEN

value: humanname
index: 0

value: en
index: 1

value: src

value: birthDate

value: birthDate

value: patient

value: variable

value: birthTime

value: birthTime

value: DateTS

value: birthDate
index: 0

value: birthTime
index: 1

value: src

value: gender

value: v

value: $this

value: patient

value: variable

value: administrativeGenderCode

value: adminGender

value: gender

index: 0
structure map.group.rule.source.context:
  value: v

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: code
structure map.group.rule.target.transform:
  value: translate
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value id:
    value: v
structure map.group.rule.target.parameter:
  index: 1
  structure map.group.rule.target.parameter.value string:
    value: http://hl7.org/fhir/ConceptMap/cm-administrative-gender-v3
structure map.group.rule.target.parameter:
  index: 2
  structure map.group.rule.target.parameter.value string:
    value: code

value: codeSytem

index: 0
structure map.group.rule.source.context:
  value: v

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: codeSystem
structure map.group.rule.target.transform:
  value: copy
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value string:
    value: 2.16.840.1.113883.5.1

value: codeSystemName

index: 0
structure map.group.rule.source.context:
  value: v

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: codeSystemName
structure map.group.rule.target.transform:
  value: copy
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value string:
    value: HL7 AdministrativeGender

value: male

index: 0
structure map.group.rule.source.context:
  value: v
structure map.group.rule.source.variable:
  value: v
structure map.group.rule.source.condition:
  value: $this = 'male'

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: displayName
structure map.group.rule.target.transform:
  value: copy
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value string:
    value: Male

value: female

index: 0
structure map.group.rule.source.context:
  value: v
structure map.group.rule.source.variable:
  value: v
structure map.group.rule.source.condition:
  value: $this = 'female'

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: displayName
structure map.group.rule.target.transform:
  value: copy
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value string:
    value: Female

value: other

index: 0
structure map.group.rule.source.context:
  value: v
structure map.group.rule.source.variable:
  value: v
structure map.group.rule.source.condition:
  value: $this = 'other'

index: 0
structure map.group.rule.target.context:
  value: adminGender
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: displayName
structure map.group.rule.target.transform:
  value: copy
structure map.group.rule.target.parameter:
  index: 0
  structure map.group.rule.target.parameter.value string:
    value: Undifferentiated

index: 4
structure map.group.rule.name:
  value: managingOrganization
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: src
  structure map.group.rule.source.element:
    value: managingOrganization
  structure map.group.rule.source.variable:
    value: managingOrganization
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: entry
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
    structure map.group.rule.source.element:
      value: entry
    structure map.group.rule.source.variable:
      value: entry
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: providerOrganization
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.element:
        value: fullUrl
      structure map.group.rule.source.condition:
        value: ($this in %managingOrganization.reference) and $this.startsWith('urn:uuid')
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: providerOrganization
      structure map.group.rule.target.variable:
        value: providerOrganization
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: Organization2CdaOrganization
      structure map.group.rule.dependent.variable:
        value: managingOrganization
        index: 0
      structure map.group.rule.dependent.variable:
        value: providerOrganization
        index: 1
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: providerOrganization
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: organization
      structure map.group.rule.source.condition:
        value: ('Organization' + '/' + $this.id) in %managingOrganization.reference
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: patientRole
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: providerOrganization
      structure map.group.rule.target.variable:
        value: providerOrganization
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: Organization2CdaOrganization
      structure map.group.rule.dependent.variable:
        value: managingOrganization
        index: 0
      structure map.group.rule.dependent.variable:
        value: providerOrganization
        index: 1

index: 5
structure map.group.name:
  value: PractitionerAuthor
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: composition
  structure map.group.input.type:
    value: Composition
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Practitioner
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 3
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: Author
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: srcAuthor
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: composition
    structure map.group.rule.source.element:
      value: author
    structure map.group.rule.source.variable:
      value: srcauthor
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: extensionTime
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: srcauthor
      structure map.group.rule.source.element:
        value: extension
      structure map.group.rule.source.variable:
        value: extensionTime
      structure map.group.rule.source.condition:
        value: $this.url = 'http://fhir.ch/ig/ch-core/StructureDefinition/ch-ext-epr-time'
    structure map.group.rule.rule:
      index: 0
      structure map.group.rule.name:
        value: DateTime
      structure map.group.rule.source:
        index: 0
      structure map.group.rule.target:
        index: 0
      structure map.group.rule.dependent:
        index: 0
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: DateTimeBundle
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: bundle
    structure map.group.rule.source.element:
      value: timestamp
    structure map.group.rule.source.variable:
      value: valueDateTime
    structure map.group.rule.source.condition:
      value: composition.author.extension.where(url = 'http://fhir.ch/ig/ch-core/StructureDefinition/ch-ext-epr-time').empty()
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: time
    structure map.group.rule.target.variable:
      value: time
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: DateTimeTS
    structure map.group.rule.dependent.variable:
      value: valueDateTime
      index: 0
    structure map.group.rule.dependent.variable:
      value: time
      index: 1
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: assignedAuthor
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: assignedAuthor
    structure map.group.rule.target.variable:
      value: assignedAuthor
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: id
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: identifier
      structure map.group.rule.source.variable:
        value: identifier
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: assignedAuthor
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: id
      structure map.group.rule.target.variable:
        value: id
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: IdentifierII
      structure map.group.rule.dependent.variable:
        value: identifier
        index: 0
      structure map.group.rule.dependent.variable:
        value: id
        index: 1
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: telecom
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: telecom
      structure map.group.rule.source.list mode:
        value: first
      structure map.group.rule.source.variable:
        value: telecom
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: assignedAuthor
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: telecom
      structure map.group.rule.target.variable:
        value: tel
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: ContactPointTEL
      structure map.group.rule.dependent.variable:
        value: telecom
        index: 0
      structure map.group.rule.dependent.variable:
        value: tel
        index: 1
  structure map.group.rule.rule:
    index: 2
    structure map.group.rule.name:
      value: address
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: address
      structure map.group.rule.source.variable:
        value: address

value: extensionTime

value: valueDateTime

value: valueDateTime

value: tgt

value: variable

value: time

value: time

value: DateTimeTS

value: valueDateTime
index: 0

value: time
index: 1

index: 0
structure map.group.rule.target.context:
  value: assignedAuthor
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: addr
structure map.group.rule.target.variable:
  value: ad

index: 0
structure map.group.rule.dependent.name:
  value: AddressAD
structure map.group.rule.dependent.variable:
  value: address
  index: 0
structure map.group.rule.dependent.variable:
  value: ad
  index: 1

index: 3
structure map.group.rule.name:
  value: name
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: src
  structure map.group.rule.source.element:
    value: name
  structure map.group.rule.source.variable:
    value: name
structure map.group.rule.target:
  index: 0
  structure map.group.rule.target.context:
    value: assignedAuthor
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: assignedPerson
  structure map.group.rule.target.variable:
    value: assignedPerson
structure map.group.rule.target:
  index: 1
  structure map.group.rule.target.context:
    value: assignedPerson
  structure map.group.rule.target.context type:
    value: variable
  structure map.group.rule.target.element:
    value: name
  structure map.group.rule.target.variable:
    value: en
structure map.group.rule.dependent:
  index: 0
  structure map.group.rule.dependent.name:
    value: HumanNameEN
  structure map.group.rule.dependent.variable:
    value: name
    index: 0
  structure map.group.rule.dependent.variable:
    value: en
    index: 1

index: 4
structure map.group.rule.name:
  value: patient
structure map.group.rule.source:
  index: 0
  structure map.group.rule.source.context:
    value: bundle
  structure map.group.rule.source.element:
    value: entry
  structure map.group.rule.source.variable:
    value: entry
structure map.group.rule.rule:
  index: 0
  structure map.group.rule.name:
    value: uuid
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: fullUrl
    structure map.group.rule.source.condition:
      value: ($this in %composition.author.reference) and $this.startsWith('urn:uuid')
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: organization
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: entry
      structure map.group.rule.source.type:
        value: Organization
      structure map.group.rule.source.element:
        value: resource
      structure map.group.rule.source.variable:
        value: organization
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: assignedAuthor
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: representedOrganization
      structure map.group.rule.target.variable:
        value: cdaorganization
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: Organization2CdaOrganization
      structure map.group.rule.dependent.variable:
        value: organization
        index: 0
      structure map.group.rule.dependent.variable:
        value: cdaorganization
        index: 1
structure map.group.rule.rule:
  index: 1
  structure map.group.rule.name:
    value: organization
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: entry
    structure map.group.rule.source.element:
      value: resource
    structure map.group.rule.source.variable:
      value: organization
    structure map.group.rule.source.condition:
      value: ('Organization' + '/' + $this.id) in %composition.author.reference
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: assignedAuthor
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: representedOrganization
    structure map.group.rule.target.variable:
      value: cdaorganization
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: Organization2CdaOrganization
    structure map.group.rule.dependent.variable:
      value: organization
      index: 0
    structure map.group.rule.dependent.variable:
      value: cdaorganization
      index: 1

index: 6
structure map.group.name:
  value: OrganizationCustodian
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Organization
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: Custodian
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: assignedCustodian
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: assignedCustodian
    structure map.group.rule.target.variable:
      value: assignedCustodian
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: representedCustodianOrganization
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: assignedCustodian
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: representedCustodianOrganization
      structure map.group.rule.target.variable:
        value: representedCustodianOrganization
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: Organization2CdaOrganizationCustodian
      structure map.group.rule.dependent.variable:
        value: src
        index: 0
      structure map.group.rule.dependent.variable:
        value: representedCustodianOrganization
        index: 1

index: 7
structure map.group.name:
  value: Organization2CdaOrganizationCustodian
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Organization
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: CdaOrganization
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: id
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: identifier
    structure map.group.rule.source.variable:
      value: identifier
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: id
    structure map.group.rule.target.variable:
      value: id
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: IdentifierII
    structure map.group.rule.dependent.variable:
      value: identifier
      index: 0
    structure map.group.rule.dependent.variable:
      value: id
      index: 1
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: name
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: name
    structure map.group.rule.source.variable:
      value: name
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: name
    structure map.group.rule.target.variable:
      value: orgname
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: orgname
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: other
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value id:
        value: name
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: address
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: address
    structure map.group.rule.source.variable:
      value: address
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: addr
    structure map.group.rule.target.variable:
      value: ad
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: AddressAD
    structure map.group.rule.dependent.variable:
      value: address
      index: 0
    structure map.group.rule.dependent.variable:
      value: ad
      index: 1
structure map.group.rule:
  index: 3
  structure map.group.rule.name:
    value: telecom
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: telecom
    structure map.group.rule.source.list mode:
      value: first
    structure map.group.rule.source.variable:
      value: telecom
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: telecom
    structure map.group.rule.target.variable:
      value: tel
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: ContactPointTEL
    structure map.group.rule.dependent.variable:
      value: telecom
      index: 0
    structure map.group.rule.dependent.variable:
      value: tel
      index: 1
  structure map.group.rule.documentation:
    value: target telecom is 0..1

index: 8
structure map.group.name:
  value: Organization2CdaOrganization
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Organization
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: CdaOrganization
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: id
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: identifier
    structure map.group.rule.source.variable:
      value: identifier
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: id
    structure map.group.rule.target.variable:
      value: id
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: IdentifierII
    structure map.group.rule.dependent.variable:
      value: identifier
      index: 0
    structure map.group.rule.dependent.variable:
      value: id
      index: 1
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: name
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: name
    structure map.group.rule.source.variable:
      value: name
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: name
    structure map.group.rule.target.variable:
      value: orgname
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: orgname
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: other
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value id:
        value: name
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: address
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: address
    structure map.group.rule.source.variable:
      value: address
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: addr
    structure map.group.rule.target.variable:
      value: ad
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: AddressAD
    structure map.group.rule.dependent.variable:
      value: address
      index: 0
    structure map.group.rule.dependent.variable:
      value: ad
      index: 1
structure map.group.rule:
  index: 3
  structure map.group.rule.name:
    value: telecom
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
    structure map.group.rule.source.element:
      value: telecom
    structure map.group.rule.source.variable:
      value: telecom
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: telecom
    structure map.group.rule.target.variable:
      value: tel
  structure map.group.rule.dependent:
    index: 0
    structure map.group.rule.dependent.name:
      value: ContactPointTEL
    structure map.group.rule.dependent.variable:
      value: telecom
      index: 0
    structure map.group.rule.dependent.variable:
      value: tel
      index: 1

index: 9
structure map.group.name:
  value: PractitionerLegalAuthenticator
structure map.group.type mode:
  value: none
structure map.group.input:
  index: 0
  structure map.group.input.name:
    value: bundle
  structure map.group.input.type:
    value: Bundle
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 1
  structure map.group.input.name:
    value: composition
  structure map.group.input.type:
    value: Composition
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 2
  structure map.group.input.name:
    value: src
  structure map.group.input.type:
    value: Practitioner
  structure map.group.input.mode:
    value: source
structure map.group.input:
  index: 3
  structure map.group.input.name:
    value: tgt
  structure map.group.input.type:
    value: LegalAuthenticator
  structure map.group.input.mode:
    value: target
structure map.group.rule:
  index: 0
  structure map.group.rule.name:
    value: templateId
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: templateId
    structure map.group.rule.target.variable:
      value: templateId
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: templateId
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: root
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value string:
        value: 2.16.756.5.30.1.1.10.2.5
structure map.group.rule:
  index: 1
  structure map.group.rule.name:
    value: time
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: composition
    structure map.group.rule.source.element:
      value: attester
    structure map.group.rule.source.variable:
      value: attester
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: timestamp
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: attester
      structure map.group.rule.source.element:
        value: time
      structure map.group.rule.source.variable:
        value: srcTime
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: tgt
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: time
      structure map.group.rule.target.variable:
        value: time
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: InstantTS
      structure map.group.rule.dependent.variable:
        value: srcTime
        index: 0
      structure map.group.rule.dependent.variable:
        value: time
        index: 1
structure map.group.rule:
  index: 2
  structure map.group.rule.name:
    value: signature
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: signatureCode
    structure map.group.rule.target.variable:
      value: signatureCode
  structure map.group.rule.target:
    index: 1
    structure map.group.rule.target.context:
      value: signatureCode
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: code
    structure map.group.rule.target.transform:
      value: copy
    structure map.group.rule.target.parameter:
      index: 0
      structure map.group.rule.target.parameter.value string:
        value: S
  structure map.group.rule.documentation:
    value: src -> tgt.signatureCode = 'S' "S";
structure map.group.rule:
  index: 3
  structure map.group.rule.name:
    value: assignedEntity
  structure map.group.rule.source:
    index: 0
    structure map.group.rule.source.context:
      value: src
  structure map.group.rule.target:
    index: 0
    structure map.group.rule.target.context:
      value: tgt
    structure map.group.rule.target.context type:
      value: variable
    structure map.group.rule.target.element:
      value: assignedEntity
    structure map.group.rule.target.variable:
      value: assignedEntity
  structure map.group.rule.rule:
    index: 0
    structure map.group.rule.name:
      value: identifier
    structure map.group.rule.source:
      index: 0
      structure map.group.rule.source.context:
        value: src
      structure map.group.rule.source.element:
        value: identifier
      structure map.group.rule.source.variable:
        value: identifier
    structure map.group.rule.target:
      index: 0
      structure map.group.rule.target.context:
        value: assignedEntity
      structure map.group.rule.target.context type:
        value: variable
      structure map.group.rule.target.element:
        value: id
      structure map.group.rule.target.variable:
        value: id
    structure map.group.rule.dependent:
      index: 0
      structure map.group.rule.dependent.name:
        value: IdentifierII
      structure map.group.rule.dependent.variable:
        value: identifier
        index: 0
      structure map.group.rule.dependent.variable:
        value: id
        index: 1
  structure map.group.rule.rule:
    index: 1
    structure map.group.rule.name:
      value: name
    structure map.group.rule.source:
      index: 0

value: src

value: name

value: name

index: 0
structure map.group.rule.target.context:
  value: assignedEntity
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: assignedPerson
structure map.group.rule.target.variable:
  value: assignedPerson

index: 1
structure map.group.rule.target.context:
  value: assignedPerson
structure map.group.rule.target.context type:
  value: variable
structure map.group.rule.target.element:
  value: name
structure map.group.rule.target.variable:
  value: en

index: 0
structure map.group.rule.dependent.name:
  value: HumanNameEN
structure map.group.rule.dependent.variable:
  value: name
  index: 0
structure map.group.rule.dependent.variable:
  value: en
  index: 1