Release 5

This page is part of the FHIR Specification (v5.0.0: R5 - STU). This is the current published version. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3

Example StructureMap/example (XML)

FHIR Infrastructure Work GroupMaturity Level: N/AStandards Status: InformativeCompartments: No defined compartments

Raw XML (canonical form + also see XML Format Specification)

Jump past Narrative

Example (id = "example")

<?xml version="1.0" encoding="UTF-8"?>

<StructureMap xmlns="http://hl7.org/fhir">
  <id value="example"/> 
  <text> 
    <status value="generated"/> 
    <div xmlns="http://www.w3.org/1999/xhtml">
      <pre class="fml">

        <span style="color: #cc00cc">/// 
          <b> url</b>  = 
        </span> 
        <span style="color: blue">'http://hl7.org/fhir/StructureMap/example'</span> 

        <span style="color: #cc00cc">/// 
          <b> name</b>  = 
        </span> 
        <span style="color: blue">'ExampleMap'</span> 

        <span style="color: #cc00cc">/// 
          <b> title</b>  = 
        </span> 
        <span style="color: blue">'Example Map'</span> 

        <span style="color: #cc00cc">/// 
          <b> status</b>  = 
        </span> 
        <span style="color: blue">'draft'</span> 


        <span style="color: navy">// </span> 
        <span style="color: green">test -&gt; testValue</span> 

        <b> group </b> Examples
        <span style="color: navy">(</span> 
        <b> source</b>  
        <span style="color: maroon">testSrc</span> , 
        <b> target</b>  
        <span style="color: maroon">testTgt</span> 
        <span style="color: navy">)</span> 
        <span style="color: navy"> {
</span>   testSrc.test
        <span style="color: navy"> : </span> SourceClassA
        <b>  as </b> 
        <span style="color: maroon">t</span> 
        <span style="color: navy">
          <b>  -&gt; </b> 
        </span> testTgt.testValue = 
        <b> copy</b> 
        <span style="color: navy">(</span> 
        <span style="color: navy">)</span>  
        <i> &quot;rule1&quot;</i> 
        <span style="color: navy">;</span> 

        <span style="color: navy">}

</span> 
      </pre> 
    </div> 
  </text> 
  <url value="http://hl7.org/fhir/StructureMap/example"/> 
  <identifier> 
    <system value="urn:ietf:rfc:3986"/> 
    <value value="urn:oid:2.16.840.1.113883.4.642.13.2"/> 
  </identifier> 
  <version value="5.0.0"/> 
  <name value="ExampleMap"/> 
  <title value="Example Map"/> 
  <status value="draft"/> 
  <experimental value="true"/> 
  <date value="2017-03-09"/> 
  <publisher value="HL7 FHIR Standard"/> 
  <contact> 
    <telecom> 
      <system value="url"/> 
      <value value="http://hl7.org/fhir"/> 
    </telecom> 
  </contact> 
  <description value="Example Structure Map"/> 
  <jurisdiction> 
    <coding> 
      <system value="http://unstats.un.org/unsd/methods/m49/m49.htm"/> 
      <code value="009"/> 
      <display value="Oceania"/> 
    </coding> 
  </jurisdiction> 
  <group> 
    <name value="Examples"/> 
    <documentation value="test -&gt; testValue"/> 
    <input> 
      <name value="testSrc"/> 
      <mode value="source"/> 
    </input> 
    <input> 
      <name value="testTgt"/> 
      <mode value="target"/> 
    </input> 
    <rule> 
      <name value="rule1"/> 
      <source> 
        <context value="testSrc"/> 
        <type value="SourceClassA"/> 
        <element value="test"/> 
        <variable value="t"/> 
      </source> 
      <target> 
        <context value="testTgt"/> 
        <element value="testValue"/> 
        <transform value="copy"/> 
      </target> 
    </rule> 
  </group> 
</StructureMap> 

Usage note: every effort has been made to ensure that the examples are correct and useful, but they are not a normative part of the specification.