<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="CancerCarePlan" />
  <meta>
    <versionId value="2" />
    <lastUpdated value="2016-11-27T05:41:22.080+00:00" />
  </meta>
  <url value="http://icecoldfhirga.tech/baseDstu3/StructureDefinition/CancerCarePlan" />
  <identifier>
    <system value="http://clinfhir.com" />
    <value value="author" />
  </identifier>
  <name value="CancerCarePlan" />
  <status value="active" />
  <experimental value="true" />
  <publisher value="http://icecoldfhirga.tech/baseDstu3/" />
  <kind value="resource" />
  <abstract value="false" />
  <snapshot>
    <element id="CarePlan">
      <path value="CarePlan" />
      <short value="Healthcare plan for patient or group" />
      <definition value="Describes the intention of how one or more practitioners intend to deliver care for a particular patient, group or community for a period of time, possibly limited to care for a specific condition or set of conditions." />
      <alias value="Care Team" />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="DomainResource" />
      </type>
      <mapping>
        <identity value="rim" />
        <map value="Act[classCode=PCPR, moodCode=INT]" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="clinical.careprovision" />
      </mapping>
    </element>
    <element id="CarePlan.id">
      <path value="CarePlan.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="CarePlan.meta">
      <path value="CarePlan.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="CarePlan.text">
      <path value="CarePlan.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="CarePlan.identifier">
      <path value="CarePlan.identifier" />
      <short value="External Ids for this plan" />
      <definition value="This records identifiers associated with this care plan 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="PTH-3" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".id" />
      </mapping>
    </element>
    <element id="CarePlan.subject">
      <path value="CarePlan.subject" />
      <short value="Who care plan is for" />
      <definition value="Identifies the patient or group whose intended care is described by the plan." />
      <min value="0" />
      <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=PAT].role[classCode=PAT]" />
      </mapping>
    </element>
    <element id="CarePlan.status">
      <path value="CarePlan.status" />
      <short value="proposed | draft | active | completed | cancelled" />
      <definition value="Indicates whether the plan is currently being acted upon, represents future intentions or is now a historical record." />
      <requirements value="Allows clinicians to determine whether the plan is actionable or not." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="code" />
      </type>
      <isModifier value="true" />
      <isSummary value="true" />
      <binding>
        <strength value="required" />
        <description value="Indicates whether the plan is currently being acted upon, represents future intentions or is now a historical record." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-status" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="PTH-5" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".statusCode planned = new active = active completed = completed" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="status" />
      </mapping>
    </element>
    <element id="CarePlan.context">
      <path value="CarePlan.context" />
      <short value="Created in context of" />
      <definition value="Identifies the context in which this particular CarePlan is defined." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Encounter" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/EpisodeOfCare" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="Associated PV1" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value="." />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="context" />
      </mapping>
      <comments value="Activities conducted as a result of the care plan may well occur as part of other encounters/episodes." />
    </element>
    <element id="CarePlan.period">
      <path value="CarePlan.period" />
      <short value="Time period plan covers" />
      <definition value="Indicates when the plan did (or is intended to) come into effect and end." />
      <requirements value="Allows tracking what plan(s) are in effect at a particular time." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Period" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="GOL-7 / GOL-8" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".effectiveTime" />
      </mapping>
      <comments value="Any activities scheduled as part of the plan should be constrained to the specified period." />
    </element>
    <element id="CarePlan.author">
      <path value="CarePlan.author" />
      <short value="Who is responsible for contents of the plan" />
      <definition value="Identifies the individual(s) or ogranization who is responsible for the content of the care plan." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Patient" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Practitioner" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/RelatedPerson" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Organization" />
      </type>
      <isSummary value="true" />
      <comments value="Collaborative care plans may have multiple authors." />
    </element>
    <element id="CarePlan.modified">
      <path value="CarePlan.modified" />
      <short value="When last updated" />
      <definition value="Identifies the most recent date on which the plan has been revised." />
      <requirements value="Indicates how current the plan is." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="dateTime" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="PTH-6" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=AUT].time" />
      </mapping>
    </element>
    <element id="CarePlan.category">
      <path value="CarePlan.category" />
      <short value="Type of plan" />
      <definition value="Identifies what &quot;kind&quot; of plan this is to support differentiation between multiple co-existing plans; e.g. &quot;Home health&quot;, &quot;psychiatric&quot;, &quot;asthma&quot;, &quot;disease management&quot;, &quot;wellness plan&quot;, etc." />
      <requirements value="Used for filtering what plan(s) are retrieved and displayed to different types of users." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <isSummary value="true" />
      <binding>
        <strength value="example" />
        <description value="Identifies what &quot;kind&quot; of plan this is to support differentiation between multiple co-existing plans; e.g. &quot;Home health&quot;, &quot;psychiatric&quot;, &quot;asthma&quot;, &quot;disease management&quot;, etc." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-category" />
        </valueSetReference>
      </binding>
      <comments value="There may be multiple axis of categorization and one plan may serve multiple purposes.  In some cases, this may be redundant with references to CarePlan.concern." />
    </element>
    <element id="CarePlan.description">
      <path value="CarePlan.description" />
      <short value="Summary of nature of plan" />
      <definition value="A description of the scope and nature of the plan." />
      <requirements value="Provides more detail than conveyed by category." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="string" />
      </type>
      <isSummary value="true" />
    </element>
    <element id="CarePlan.addresses">
      <path value="CarePlan.addresses" />
      <short value="Health issues this plan addresses" />
      <definition value="Identifies the conditions/problems/concerns/diagnoses/etc. whose management and/or mitigation are handled by this plan." />
      <requirements value="Links plan to the conditions it manages.  Also scopes plans - multiple plans may exist addressing different concerns." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="v2" />
        <map value="PRB-4" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".actRelationship[typeCode=SUBJ].target[classCode=CONC, moodCode=EVN]" />
      </mapping>
    </element>
    <element id="CarePlan.support">
      <path value="CarePlan.support" />
      <short value="Information considered as part of plan" />
      <definition value="Identifies portions of the patient's record that specifically influenced the formation of the plan.  These might include co-morbidities, recent procedures, limitations, recent assessments, etc." />
      <requirements value="Identifies barriers and other considerations associated with the care plan." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Resource" />
      </type>
      <comments value="Use &quot;concern&quot; to identify specific conditions addressed by the care plan." />
    </element>
    <element id="CarePlan.relatedPlan">
      <path value="CarePlan.relatedPlan" />
      <short value="Plans related to this one" />
      <definition value="Identifies CarePlans with some sort of formal relationship to the current plan." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="BackboneElement" />
      </type>
      <comments value="Relationships are uni-directional with the &quot;newer&quot; plan pointing to the older one." />
    </element>
    <element id="CarePlan.relatedPlan.code">
      <path value="CarePlan.relatedPlan.code" />
      <short value="includes | replaces | fulfills" />
      <definition value="Identifies the type of relationship this plan has to the target plan." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="code" />
      </type>
      <binding>
        <strength value="required" />
        <description value="Codes identifying the types of relationships between two plans." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-relationship" />
        </valueSetReference>
      </binding>
      <comments value="Read the relationship as &quot;this plan&quot; [relatedPlan.code] &quot;relatedPlan.plan&quot;; e.g. This plan includes Plan B.  Additional relationship types can be proposed for future releases or handled as extensions." />
    </element>
    <element id="CarePlan.relatedPlan.plan">
      <path value="CarePlan.relatedPlan.plan" />
      <short value="Plan relationship exists with" />
      <definition value="A reference to the plan to which a relationship is asserted." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/CarePlan" />
      </type>
    </element>
    <element id="CarePlan.participant">
      <path value="CarePlan.participant" />
      <short value="Who's involved in plan?" />
      <definition value="Identifies all people and organizations who are expected to be involved in the care envisioned by this plan." />
      <requirements value="Allows representation of care teams, helps scope care plan.  In some cases may be a determiner of access permissions." />
      <alias value="Care Team" />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="BackboneElement" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="REL (REL.4 is always the Patient) ( or PRT?)" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=PFM]" />
      </mapping>
    </element>
    <element id="CarePlan.participant.role">
      <path value="CarePlan.participant.role" />
      <short value="Type of involvement" />
      <definition value="Indicates specific responsibility of an individual within the care plan; e.g. &quot;Primary physician&quot;, &quot;Team coordinator&quot;, &quot;Caregiver&quot;, etc." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Indicates specific responsibility of an individual within the care plan; e.g. &quot;Primary physician&quot;, &quot;Team coordinator&quot;, &quot;Caregiver&quot;, etc." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/participant-role" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="REL.2 (or PRT-4?)" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".functionCode" />
      </mapping>
      <comments value="Roles may sometimes be inferred by type of Practitioner.  These are relationships that hold only within the context of the care plan.  General relationships should be handled as properties of the Patient resource directly." />
    </element>
    <element id="CarePlan.participant.member">
      <path value="CarePlan.participant.member" />
      <short value="Who is involved" />
      <definition value="The specific person or organization who is participating/expected to participate in the care plan." />
      <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/RelatedPerson" />
      </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/Organization" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="REL.5 (or PRT-5 : ( PRV-4 {provider participations} ) / PRT-5 : ( PRV-4  {non-provider person participations} ) / PRT-5 : ( PRV-4 = (patient non-subject of care) ) / PRT-8?)" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".role" />
      </mapping>
      <comments value="Patient only needs to be listed if they have a role other than &quot;subject of care&quot;.  Member is optional because some participants may be known only by their role, particularly in draft plans." />
    </element>
    <element id="CarePlan.goal">
      <path value="CarePlan.goal" />
      <short value="Desired outcome of plan" />
      <definition value="Describes the intended objective(s) of carrying out the care plan." />
      <requirements value="Provides context for plan.  Allows plan effectiveness to be evaluated by clinicians." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Goal" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="GOL.1" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode&lt;=OBJ]." />
      </mapping>
      <comments value="Goal can be achieving a particular change or merely maintaining a current state or even slowing a decline." />
    </element>
    <element id="CarePlan.activity">
      <path value="CarePlan.activity" />
      <short value="Action to occur as part of plan" />
      <definition value="Identifies a planned action to occur as part of the plan.  For example, a medication to be used, lab tests to perform, self-monitoring, education, etc." />
      <requirements value="Allows systems to prompt for performance of planned activities, and validate plans against best practice." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="BackboneElement" />
      </type>
      <constraint>
        <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-expression">
          <valueString value="detail.empty() or reference.empty()" />
        </extension>
        <key value="cpl-3" />
        <severity value="error" />
        <human value="Provide a reference or detail, not both" />
        <xpath value="not(exists(f:detail)) or not(exists(f:reference))" />
      </constraint>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP].target" />
      </mapping>
    </element>
    <element id="CarePlan.activity.actionResulting">
      <path value="CarePlan.activity.actionResulting" />
      <short value="Appointments, orders, etc." />
      <definition value="Resources that describe follow-on actions resulting from the plan, such as drug prescriptions, encounter records, appointments, etc." />
      <requirements value="Links plan to resulting actions." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Resource" />
      </type>
      <mapping>
        <identity value="rim" />
        <map value=".inboundRelationship[typeCode=FLFS].source" />
      </mapping>
    </element>
    <element id="CarePlan.activity.progress">
      <path value="CarePlan.activity.progress" />
      <short value="Comments about the activity status/progress" />
      <definition value="Notes about the adherence/status/progress of the activity." />
      <requirements value="Can be used to capture information about adherence, progress, concerns, etc." />
      <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>
      <comments value="This element should NOT be used to describe the activity to be performed - that occurs either within the resource pointed to by activity.detail.reference or in activity.detail.description." />
    </element>
    <element id="CarePlan.activity.reference">
      <path value="CarePlan.activity.reference" />
      <short value="Activity details defined in specific resource" />
      <definition value="The details of the proposed activity represented in a specific resource." />
      <requirements value="Details in a form consistent with other applications and contexts of use." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Appointment" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/CommunicationRequest" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/DeviceUseRequest" />
      </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/MedicationOrder" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/NutritionOrder" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Order" />
      </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/ProcessRequest" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/ReferralRequest" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/SupplyRequest" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/VisionPrescription" />
      </type>
      <condition value="cpl-3" />
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP].target" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail">
      <path value="CarePlan.activity.detail" />
      <short value="In-line definition of activity" />
      <definition value="A simple summary of a planned activity suitable for a general care plan system (e.g. form driven) that doesn't know about specific resources such as procedure etc." />
      <requirements value="Details in a simple form for generic care plan systems." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="BackboneElement" />
      </type>
      <condition value="cpl-3" />
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP, subsetCode=SUMM].target" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.category">
      <path value="CarePlan.activity.detail.category" />
      <short value="diet | drug | encounter | observation | procedure | supply | other" />
      <definition value="High-level categorization of the type of activity in a care plan." />
      <requirements value="May determine what types of extensions are permitted." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="High-level categorization of the type of activity in a care plan." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-activity-category" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="rim" />
        <map value=".inboundRelationship[typeCode=COMP].source[classCode=LIST].code" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.code">
      <path value="CarePlan.activity.detail.code" />
      <short value="Detail type of activity" />
      <definition value="Detailed description of the type of planned activity; e.g. What lab test, what procedure, what kind of encounter." />
      <requirements value="Allows matching performed to planned as well as validation against protocols." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Detailed description of the type of activity; e.g. What lab test, what procedure, what kind of encounter." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-activity" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="OBR-4 / RXE-2 / RXO-1  / RXD-2" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".code" />
      </mapping>
      <comments value="Tends to be less relevant for activities involving particular products.  Codes should not convey negation - use &quot;prohibited&quot; instead." />
    </element>
    <element id="CarePlan.activity.detail.reasonCode">
      <path value="CarePlan.activity.detail.reasonCode" />
      <short value="Why activity should be done" />
      <definition value="Provides the rationale that drove the inclusion of this particular activity as part of the plan." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Identifies why a care plan activity is needed.  Can include any health condition codes as well as such concepts as &quot;general wellness&quot;, prophylaxis, surgical preparation, etc." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/activity-reason" />
        </valueSetReference>
      </binding>
      <comments value="This could be a diagnosis code.  If a full condition record exists or additional detail is needed, use reasonCondition instead." />
    </element>
    <element id="CarePlan.activity.detail.reasonReference">
      <path value="CarePlan.activity.detail.reasonReference" />
      <short value="Condition triggering need for activity" />
      <definition value="Provides the health condition(s) that drove the inclusion of this particular activity as part of the plan." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition" />
      </type>
      <comments value="Conditions can be identified at the activity level that are not identified as reasons for the overall plan." />
    </element>
    <element id="CarePlan.activity.detail.goal">
      <path value="CarePlan.activity.detail.goal" />
      <short value="Goals this activity relates to" />
      <definition value="Internal reference that identifies the goals that this activity is intended to contribute towards meeting." />
      <requirements value="So that participants know the link explicitly." />
      <min value="0" />
      <max value="*" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Goal" />
      </type>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode&lt;=OBJ]." />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.status">
      <path value="CarePlan.activity.detail.status" />
      <short value="not-started | scheduled | in-progress | on-hold | completed | cancelled" />
      <definition value="Identifies what progress is being made for the specific activity." />
      <requirements value="Indicates progress against the plan, whether the activity is still relevant for the plan." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="code" />
      </type>
      <isModifier value="true" />
      <binding>
        <strength value="required" />
        <description value="Indicates where the activity is at in its overall life cycle." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/care-plan-activity-status" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="ORC-5?" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".statusCode not-started = new scheduled = not-started (and fulfillment relationship to appointent) in-progress = active on-hold = suspended completed = completed cancelled = aborted" />
      </mapping>
      <comments value="Some aspects of status can be inferred based on the resources linked in actionTaken.  Note that &quot;status&quot; is only as current as the plan was most recently updated." />
    </element>
    <element id="CarePlan.activity.detail.statusReason">
      <path value="CarePlan.activity.detail.statusReason" />
      <short value="Reason for current status" />
      <definition value="Provides reason why the activity isn't yet started, is on hold, was cancelled, etc." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </type>
      <binding>
        <strength value="example" />
        <description value="Describes why the current activity has the status it does; e.g. &quot;Recovering from injury&quot; as a reason for non-started or on-hold, &quot;Patient does not enjoy activity&quot; as a reason for cancelling a planned activity." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/goal-status-reason" />
        </valueSetReference>
      </binding>
      <comments value="Will generally not be present if status is &quot;complete&quot;.  Be sure to prompt to update this (or at least remove the existing value) if the status is changed." />
    </element>
    <element id="CarePlan.activity.detail.prohibited">
      <path value="CarePlan.activity.detail.prohibited" />
      <short value="Do NOT do" />
      <definition value="If true, indicates that the described activity is one that must NOT be engaged in when following the plan." />
      <requirements value="Captures intention to not do something that may have been previously typical." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="boolean" />
      </type>
      <isModifier value="true" />
      <mapping>
        <identity value="rim" />
        <map value="actionNegationInd" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.scheduled[x]">
      <path value="CarePlan.activity.detail.scheduled[x]" />
      <short value="When activity is to occur" />
      <definition value="The period, timing or frequency upon which the described activity is to occur." />
      <requirements value="Allows prompting for activities and detection of missed planned activities." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Timing" />
      </type>
      <type>
        <code value="Period" />
      </type>
      <type>
        <code value="string" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="TQ1" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".effectiveTime" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.location">
      <path value="CarePlan.activity.detail.location" />
      <short value="Where it should happen" />
      <definition value="Identifies the facility where the activity will occur; e.g. home, hospital, specific clinic, etc." />
      <requirements value="Helps in planning of activity." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Location" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="OBR-24(???!!)" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=LOC].role" />
      </mapping>
      <comments value="May reference a specific clinical location or may identify a type of location." />
    </element>
    <element id="CarePlan.activity.detail.performer">
      <path value="CarePlan.activity.detail.performer" />
      <short value="Who will be responsible?" />
      <definition value="Identifies who's expected to be involved in the activity." />
      <requirements value="Helps in planning of activity." />
      <min value="0" />
      <max value="*" />
      <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/RelatedPerson" />
      </type>
      <type>
        <code value="Reference" />
        <profile value="http://hl7.org/fhir/StructureDefinition/Patient" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="PRT-5 : ( PRV-4 e {provider participations} ) / PRT-5 : ( PRV-4 e {non-provider person participations} ) / PRT-5 : ( PRV-4 = (patient non-subject of care) ) / PRT-8" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=PFM]" />
      </mapping>
      <comments value="A performer MAY also be a participant in the care plan." />
    </element>
    <element id="CarePlan.activity.detail.product[x]">
      <path value="CarePlan.activity.detail.product[x]" />
      <short value="What is to be administered/supplied" />
      <definition value="Identifies the food, drug or other product to be consumed or supplied in the activity." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="CodeableConcept" />
      </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>
      <binding>
        <strength value="example" />
        <description value="A product supplied or administered as part of a care plan activity." />
        <valueSetReference>
          <reference value="http://hl7.org/fhir/ValueSet/medication-codes" />
        </valueSetReference>
      </binding>
      <mapping>
        <identity value="v2" />
        <map value="RXE-2 / RXO-1 / RXD-2" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".participation[typeCode=PRD].role" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.dailyAmount">
      <path value="CarePlan.activity.detail.dailyAmount" />
      <short value="How to consume/day?" />
      <definition value="Identifies the quantity expected to be consumed in a given day." />
      <requirements value="Allows rough dose checking." />
      <alias value="daily dose" />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Quantity" />
        <profile value="http://hl7.org/fhir/StructureDefinition/SimpleQuantity" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="RXO-23 / RXE-19 / RXD-12" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP][classCode=SBADM].doseQuantity" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.quantity">
      <path value="CarePlan.activity.detail.quantity" />
      <short value="How much to administer/supply/consume" />
      <definition value="Identifies the quantity expected to be supplied, administered or consumed by the subject." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Quantity" />
        <profile value="http://hl7.org/fhir/StructureDefinition/SimpleQuantity" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="RXO-11 / RXE-10 / RXD-4 / RXG-5 / RXA-6 /  TQ1-2.1  *and*  RXO-12 /  RXE-11 / RXD-5 / RXG-7 / RXA-7 / TQ1-2.2" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".outboundRelationship[typeCode=COMP][classCode=SPLY].quantity" />
      </mapping>
    </element>
    <element id="CarePlan.activity.detail.description">
      <path value="CarePlan.activity.detail.description" />
      <short value="Extra info describing activity to perform" />
      <definition value="This provides a textual description of constraints on the intended activity occurrence, including relation to other activities.  It may also include objectives, pre-conditions and end-conditions.  Finally, it may convey specifics about the activity such as body site, method, route, etc." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="string" />
      </type>
      <mapping>
        <identity value="v2" />
        <map value="NTE?" />
      </mapping>
      <mapping>
        <identity value="rim" />
        <map value=".text" />
      </mapping>
    </element>
    <element id="CarePlan.note">
      <path value="CarePlan.note" />
      <short value="Comments about the plan" />
      <definition value="General notes about the care plan not covered elsewhere." />
      <requirements value="Used to capture information that applies to the plan as a whole that doesn't fit into discrete elements." />
      <min value="0" />
      <max value="1" />
      <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>
  </snapshot>
  <code>
    <system value="http://fhir.hl7.org.nz/NamingSystem/application" />
    <code value="clinfhir" />
  </code>
</StructureDefinition>