<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="task-replaces" />
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-wg">
    <valueCode value="oo" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm">
    <valueInteger value="1" />
  </extension>
  <url value="http://hl7.org/fhir/StructureDefinition/task-replaces" />
  <version value="4.6.0" />
  <name value="replaces" />
  <title value="replaces" />
  <status value="draft" />
  <date value="2017-02-16" />
  <publisher value="Health Level Seven, Inc. - FHIR I WG" />
  <contact>
    <telecom>
      <system value="url" />
      <value value="HL7" />
    </telecom>
  </contact>
  <description value="Completed or terminated task(s) whose function is taken by this new task." />
  <fhirVersion value="4.6.0" />
  <mapping>
    <identity value="workflow" />
    <uri value="http://hl7.org/fhir/workflow" />
    <name value="Workflow Pattern" />
  </mapping>
  <mapping>
    <identity value="rim" />
    <uri value="http://hl7.org/v3" />
    <name value="RIM Mapping" />
  </mapping>
  <kind value="complex-type" />
  <abstract value="false" />
  <context>
    <type value="element" />
    <expression value="Task" />
  </context>
  <type value="Extension" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Extension" />
  <derivation value="constraint" />
  <differential>
    <element id="Extension">
      <path value="Extension" />
      <short value="Task(s) replaced by this Task" />
      <definition value="Completed or terminated task(s) whose function is taken by this new task." />
      <comment value="The replacement could be because the initial task was immediately rejected (due to an issue) or because the previous task was completed, but the need for the action described by the task remains ongoing." />
      <min value="0" />
      <max value="*" />
      <mapping>
        <identity value="workflow" />
        <map value="Request.replaces" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=RPLC].target" />
      </mapping>
    </element>
    <element id="Extension.extension">
      <path value="Extension.extension" />
      <max value="0" />
    </element>
    <element id="Extension.url">
      <path value="Extension.url" />
      <fixedUri value="http://hl7.org/fhir/StructureDefinition/task-replaces" />
    </element>
    <element id="Extension.value[x]">
      <path value="Extension.value[x]" />
      <min value="1" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/Task" />
      </type>
    </element>
  </differential>
</StructureDefinition>