FHIR Cross-Version Mapping Pack
0.1.0 - Ballot for Release 5.1.0 International flag

FHIR Cross-Version Mapping Pack, published by HL7 International / FHIR Infrastructure. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/HL7/fhir-cross-version/ and changes regularly. See the Directory of published versions

StructureMap: MessageHeader Transforms: R3 to R4

Official URL: http://hl7.org/fhir/StructureMap/MessageHeader3to4 Version: 0.1.0
Standards status: Draft Maturity Level: 1 Computable Name: MessageHeader3to4

MessageHeaderTransformsR3toR4

/// url = 'http://hl7.org/fhir/StructureMap/MessageHeader3to4'
/// name = 'MessageHeader3to4'
/// title = 'MessageHeader Transforms: R3 to R4'
/// status = 'active'

uses "http://hl7.org/fhir/3.0/MessageHeader" alias MessageHeaderR3 as source
uses "http://hl7.org/fhir/4.0/MessageHeader" alias MessageHeader as target

imports "http://hl7.org/fhir/StructureMap/*3to4"

group MessageHeader(source src : MessageHeaderR3, target tgt : MessageHeader) extends DomainResource <<type+>> {
  src.event -> tgt.event;
  src.destination as vs0 -> tgt.destination as vt0 then destination(vs0, vt0, src);
  src.sender -> tgt.sender;
  src.timestamp as vs ->  tgt.extension as ext,  ext.url = 'http://hl7.org/fhir/3.0/StructureDefinition/extension-MessageHeader.timestamp',  ext.value = vs;
  src.enterer -> tgt.enterer;
  src.author -> tgt.author;
  src.source as vs0 -> tgt.source as vt0 then source(vs0, vt0);
  src.responsible -> tgt.responsible;
  src.reason -> tgt.reason;
  src.response as vs0 -> tgt.response as vt0 then response(vs0, vt0);
  src.focus -> tgt.focus;
}

group destination(source src, target tgt, source msrc) extends BackboneElement {
  src.name -> tgt.name;
  src.target -> tgt.target;
  src.endpoint -> tgt.endpoint;
  msrc.receiver -> tgt.receiver;
}

group source(source src, target tgt) extends BackboneElement {
  src.name -> tgt.name;
  src.software -> tgt.software;
  src.version -> tgt.version;
  src.contact -> tgt.contact;
  src.endpoint -> tgt.endpoint;
}

group response(source src, target tgt) extends BackboneElement {
  src.identifier -> tgt.identifier;
  src.code -> tgt.code;
  src.details -> tgt.details;
}