<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="CancerProcedure" />
  <meta>
    <versionId value="2" />
    <lastUpdated value="2016-11-27T05:38:32.674+00:00" />
  </meta>
  <url value="http://icecoldfhirga.tech/baseDstu3/StructureDefinition/CancerProcedure" />
  <identifier>
    <system value="http://clinfhir.com" />
    <value value="author" />
  </identifier>
  <name value="CancerProcedure" />
  <status value="active" />
  <experimental value="true" />
  <publisher value="http://icecoldfhirga.tech/baseDstu3/" />
  <kind value="resource" />
  <abstract value="false" />
  <snapshot>
    <element id="Procedure">
      <path value="Procedure" />
      <short value="An action that is being or was performed on a patient" />
      <definition value="An action that is or was performed on a patient. This can be a physical intervention like an operation, or less invasive like counseling or hypnotherapy." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="DomainResource" />
      </type>
      <constraint>
        <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-expression">
          <valueString value="reasonNotPerformed.empty() or notPerformed = 'true'" />
        </extension>
        <key value="pro-1" />
        <severity value="error" />
        <human value="Reason not performed is only permitted if notPerformed indicator is true" />
        <xpath value="not(exists(f:reasonNotPerformed)) or f:notPerformed/@value=true()" />
      </constraint>
      <mapping>
        <identity value="rim" />
        <map value="Procedure[moodCode=EVN]" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="clinical.general" />
      </mapping>
    </element>
    <element id="Procedure.id">
      <path value="Procedure.id" />
      <definition value="Id" />
      <min value="0" />
      <max value="1" />
      <base>
        <path value="Resource.id" />
        <min value="0" />
        <max value="1" />
      </base>
      <type>
        <code value="id" />
      </type>
    </element>
    <element id="Procedure.meta">
      <path value="Procedure.meta" />
      <definition value="The meta element" />
      <min value="0" />
      <max value="1" />
      <base>
        <path value="Resource.meta" />
        <min value="0" />
        <max value="1" />
      </base>
      <type>
        <code value="Meta" />
      </type>
    </element>
    <element id="Procedure.text">
      <path value="Procedure.text" />
      <definition value="Narrative" />
      <min value="0" />
      <max value="1" />
      <base>
        <path value="DomainResource.text" />
        <min value="0" />
        <max value="*" />
      </base>
      <type>
        <code value="Narrative" />
      </type>
    </element>
    <element id="Procedure.identifier">
      <path value="Procedure.identifier" />
      <short value="External Identifiers for this procedure" />
      <definition value="This records identifiers associated with this procedure that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation)." />
      <requirements value="Need to allow connection to a wider workflow." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Identifier" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="Some combination of ORC-2 / ORC-3 / OBR-2 / OBR-3 / IPC-1 / IPC-2 / IPC-3 / IPC-4" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".id" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="id" />
      </mapping>
    </element>
    <element id="Procedure.subject">
      <path value="Procedure.subject" />
      <short value="Who the procedure was performed on" />
      <definition value="The person, animal or group on which the procedure was performed." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Patient" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Group" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="PID-3" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=SBJ].role" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="who.focus" />
      </mapping>
    </element>
    <element id="Procedure.status">
      <path value="Procedure.status" />
      <short value="in-progress | aborted | completed | entered-in-error" />
      <definition value="A code specifying the state of the procedure. Generally this will be in-progress or completed state." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="code" />
      </type>
      <isModifier value="true" />
      <isSummary value="true" />
      <binding>
        <strength value="required" />
        <description value="A code specifying the state of the procedure." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-status" />
        </valueSetReference>
      </binding>
    </element>
    <element id="Procedure.category">
      <path value="Procedure.category" />
      <short value="Classification of the procedure" />
      <definition value="A code that classifies the procedure for searching, sorting and display purposes (e.g. &quot;Surgical Procedure&quot;)." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="example" />
        <description value="A code that classifies a procedure for searching, sorting and display purposes." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-category" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=&quot;COMP].target[classCode=&quot;LIST&quot;, moodCode=&quot;EVN&quot;].code" />
      </mapping>
    </element>
    <element id="Procedure.code">
      <path value="Procedure.code" />
      <short value="Identification of the procedure" />
      <definition value="The specific procedure that is performed. Use text if the exact nature of the procedure cannot be coded (e.g. &quot;Laparoscopic Appendectomy&quot;)." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="preferred" />
        <description value="A code to identify a specific procedure ." />
        <valueSetUri value="http://hl7.org/fhir/ValueSet/uslab-obs-codedresults" />
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="OBR-44/OBR-45" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".code" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="class" />
      </mapping>
    </element>
    <element id="Procedure.notPerformed">
      <path value="Procedure.notPerformed" />
      <short value="True if procedure was not performed as scheduled" />
      <definition value="Set this to true if the record is saying that the procedure was NOT performed." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="boolean" />
      </type>
      <defaultValueBoolean value="false" />
      <isModifier value="true" />
      <mapping>
        <identity value="rim" />
        <map value=".actionNegationInd" />
      </mapping>
    </element>
    <element id="Procedure.reasonNotPerformed">
      <path value="Procedure.reasonNotPerformed" />
      <short value="Reason procedure was not performed" />
      <definition value="A code indicating why the procedure was not performed." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <condition value="pro-1" />
      <binding>
        <strength value="example" />
        <description value="A code that identifies the reason a procedure was not performed." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-not-performed-reason" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".reason.Observation.value" />
      </mapping>
    </element>
    <element id="Procedure.bodySite">
      <path value="Procedure.bodySite" />
      <short value="Target body sites" />
      <definition value="Detailed and structured anatomical location information. Multiple locations are allowed - e.g. multiple punch biopsies of a lesion." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="preferred" />
        <description value="Codes describing anatomical locations. May include laterality." />
        <valueSetUri value="http://hl7.org/fhir/ValueSet/body-site" />
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="OBX-20" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".targetSiteCode" />
      </mapping>
    </element>
    <element id="Procedure.reason[x]">
      <path value="Procedure.reason[x]" />
      <short value="Reason procedure performed" />
      <definition value="The reason why the procedure was performed. This may be due to a Condition, may be coded entity of some type, or may simply be present as text." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="example" />
        <description value="A code that identifies the reason a procedure is  required." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-reason" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".reasonCode" />
      </mapping>
      <comments value="e.g. endoscopy for dilatation and biopsy, combination diagnosis and therapeutic." />
    </element>
    <element id="Procedure.performer">
      <path value="Procedure.performer" />
      <short value="The people who performed the procedure" />
      <definition value="Limited to 'real' people rather than equipment." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="BackboneElement" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=PFM]" />
      </mapping>
    </element>
    <element id="Procedure.performer.actor">
      <path value="Procedure.performer.actor" />
      <short value="The reference to the practitioner" />
      <definition value="The practitioner who was involved in the procedure." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Practitioner" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Organization" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Patient" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/RelatedPerson" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="ORC-19/PRT-5" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".role" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="who.actor" />
      </mapping>
    </element>
    <element id="Procedure.performer.role">
      <path value="Procedure.performer.role" />
      <short value="The role the actor was in" />
      <definition value="For example: surgeon, anaethetist, endoscopist." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="example" />
        <description value="A code that identifies the role of a performer of the procedure." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/performer-role" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="Some combination of STF-18 / PRA-3 / PRT-4 / ROL-3 / ORC-12 / OBR-16 / PV1-7 / PV1-8 / PV1-9 / PV1-17 / OBX-25" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".functionCode" />
      </mapping>
    </element>
    <element id="Procedure.performed[x]">
      <path value="Procedure.performed[x]" />
      <short value="Date/Period the procedure was performed" />
      <definition value="The date(time)/period over which the procedure was performed. Allows a period to support complex procedures that span more than one date, and also allows for the length of the procedure to be captured." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="dateTime" />
      </type>
      <type>
        <code value="Period" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="OBR-7" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".effectiveTime" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="when.done" />
      </mapping>
    </element>
    <element id="Procedure.encounter">
      <path value="Procedure.encounter" />
      <short value="The encounter associated with the procedure" />
      <definition value="The encounter during which the procedure was performed." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Encounter" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="PV1-19" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".inboundRelationship[typeCode=COMP].source[classCode=ENC, moodCode=EVN]" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="context" />
      </mapping>
    </element>
    <element id="Procedure.location">
      <path value="Procedure.location" />
      <short value="Where the procedure happened" />
      <definition value="The location where the procedure actually happened.  E.g. a newborn at home, a tracheostomy at a restaurant." />
      <requirements value="Ties a procedure to where the records are likely kept." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Location" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="w5" />
        <map value="where" />
      </mapping>
    </element>
    <element id="Procedure.outcome">
      <path value="Procedure.outcome" />
      <short value="The result of procedure" />
      <definition value="The outcome of the procedure - did it resolve reasons for the procedure being performed?" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="example" />
        <description value="An outcome of a procedure - whether it was resolved or otherwise." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-outcome" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=OUT].target.text" />
      </mapping>
      <comments value="If outcome contains narrative text only, it can be captured using the CodeableConcept.text." />
    </element>
    <element id="Procedure.report">
      <path value="Procedure.report" />
      <short value="Any report resulting from the procedure" />
      <definition value="This could be a histology result, pathology report, surgical report, etc.." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/DiagnosticReport" />
      </type>
      <mapping>
        <identity value="rim" />
        <map value=".inboundRelationship[typeCode=SUBJ].source[classCode=OBS, moodCode=EVN]" />
      </mapping>
      <comments value="There could potentially be multiple reports - e.g. if this was a procedure which took multiple biopsies resulting in a number of anatomical pathology reports." />
    </element>
    <element id="Procedure.complication">
      <path value="Procedure.complication" />
      <short value="Complication following the procedure" />
      <definition value="Any complications that occurred during the procedure, or in the immediate post-performance period. These are generally tracked separately from the notes, which will typically describe the procedure itself rather than any 'post procedure' issues." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Codes describing complications that resulted from a procedure." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/condition-code" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value="Need specialization of OUT for this." />
      </mapping>
      <comments value="If complications are only expressed by the narrative text, they can be captured using the CodeableConcept.text." />
    </element>
    <element id="Procedure.followUp">
      <path value="Procedure.followUp" />
      <short value="Instructions for follow up" />
      <definition value="If the procedure required specific follow up - e.g. removal of sutures. The followup may be represented as a simple note, or could potentially be more complex in which case the CarePlan resource can be used." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Specific follow up required for a procedure e.g. removal of sutures." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/procedure-followup" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP].target[classCode=ACT, moodCode=INT].code" />
      </mapping>
    </element>
    <element id="Procedure.request">
      <path value="Procedure.request" />
      <short value="A request for this procedure" />
      <definition value="A reference to a resource that contains details of the request for this procedure." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/CarePlan" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/DiagnosticOrder" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/ProcedureRequest" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/ReferralRequest" />
      </type>
    </element>
    <element id="Procedure.notes">
      <path value="Procedure.notes" />
      <short value="Additional information about the procedure" />
      <definition value="Any other notes about the procedure.  E.g. the operative notes." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Annotation" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="NTE" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".inboundRelationship[typeCode=SUBJ].source[classCode=OBS, moodCode=EVN, code=&quot;annotation&quot;].value" />
      </mapping>
    </element>
    <element id="Procedure.focalDevice">
      <path value="Procedure.focalDevice" />
      <short value="Device changed in procedure" />
      <definition value="A device that is implanted, removed or otherwise manipulated (calibration, battery replacement, fitting a prosthesis, attaching a wound-vac, etc.) as a focal portion of the Procedure." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="BackboneElement" />
      </type>
    </element>
    <element id="Procedure.focalDevice.action">
      <path value="Procedure.focalDevice.action" />
      <short value="Kind of change to device" />
      <definition value="The kind of change that happened to the device during the procedure." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="required" />
        <description value="A kind of change that happened to the device during the procedure." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/device-action" />
        </valueSetReference>
      </binding>
    </element>
    <element id="Procedure.focalDevice.manipulated">
      <path value="Procedure.focalDevice.manipulated" />
      <short value="Device that was changed" />
      <definition value="The device that was manipulated (changed) during the procedure." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Device" />
      </type>
    </element>
    <element id="Procedure.used">
      <path value="Procedure.used" />
      <short value="Items used during procedure" />
      <definition value="Identifies medications, devices and any other substance used as part of the procedure." />
      <requirements value="Used for tracking contamination, etc." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Device" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Medication" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Substance" />
      </type>
      <comments value="For devices actually implanted or removed, use Procedure.device." />
    </element>
  </snapshot>
</StructureDefinition>