<StructureDefinition xmlns="http://hl7.org/fhir">
  <id value="Binary" />
  <meta>
    <lastUpdated value="2020-12-31T07:32:20.021+11:00" />
  </meta>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-category">
    <valueString value="Foundation.Other" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status">
    <valueCode value="normative" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-normative-version">
    <valueCode value="4.0.0" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm">
    <valueInteger value="5" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-security-category">
    <valueCode value="not-classified" />
  </extension>
  <extension url="http://hl7.org/fhir/StructureDefinition/structuredefinition-wg">
    <valueCode value="fhir" />
  </extension>
  <extension url="http://hl7.org/fhir/build/StructureDefinition/entered-in-error-status">
    <valueCode value="n/a (This would be handled where the binary is linked from)" />
  </extension>
  <url value="http://hl7.org/fhir/StructureDefinition/Binary" />
  <version value="4.6.0" />
  <name value="Binary" />
  <status value="active" />
  <date value="2020-12-31T07:32:20+11:00" />
  <publisher value="Health Level Seven International (FHIR Infrastructure)" />
  <contact>
    <telecom>
      <system value="url" />
      <value value="http://hl7.org/fhir" />
    </telecom>
  </contact>
  <contact>
    <telecom>
      <system value="url" />
      <value value="http://www.hl7.org/Special/committees/fiwg/index.cfm" />
    </telecom>
  </contact>
  <description value="A resource that represents the data of a single raw artifact as digital content accessible in its native format.  A Binary resource can contain any content, whether text, image, pdf, zip archive, etc." />
  <purpose value="There are situations where it is useful or required to handle pure binary content using the same framework as other resources." />
  <fhirVersion value="4.6.0" />
  <mapping>
    <identity value="rim" />
    <uri value="http://hl7.org/v3" />
    <name value="RIM Mapping" />
  </mapping>
  <mapping>
    <identity value="w5" />
    <uri value="http://hl7.org/fhir/fivews" />
    <name value="FiveWs Pattern Mapping" />
  </mapping>
  <kind value="resource" />
  <abstract value="false" />
  <type value="Binary" />
  <baseDefinition value="http://hl7.org/fhir/StructureDefinition/Resource" />
  <derivation value="specialization" />
  <differential>
    <element id="Binary">
      <path value="Binary" />
      <short value="Pure binary content defined by a format other than FHIR" />
      <definition value="A resource that represents the data of a single raw artifact as digital content accessible in its native format.  A Binary resource can contain any content, whether text, image, pdf, zip archive, etc." />
      <comment value="Typically, Binary resources are used for handling content such as:  &#xA;&#xA;* CDA Documents (i.e. with XDS) &#xA;* PDF Documents &#xA;* Images." />
      <min value="0" />
      <max value="*" />
      <mapping>
        <identity value="rim" />
        <map value="ED" />
      </mapping>
      <mapping>
        <identity value="w5" />
        <map value="infrastructure.structure" />
      </mapping>
    </element>
    <element id="Binary.contentType">
      <extension url="http://hl7.org/fhir/build/StructureDefinition/definition">
        <valueString value="The mime type of an attachment. Any valid mime type is allowed." />
      </extension>
      <extension url="http://hl7.org/fhir/build/StructureDefinition/name">
        <valueString value="MimeType" />
      </extension>
      <path value="Binary.contentType" />
      <short value="MimeType of the binary content" />
      <definition value="MimeType of the binary content represented as a standard MimeType (BCP 13)." />
      <min value="1" />
      <max value="1" />
      <type>
        <code value="code" />
      </type>
      <isSummary value="true" />
      <binding>
        <extension url="http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName">
          <valueString value="MimeType" />
        </extension>
        <extension url="http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding">
          <valueBoolean value="true" />
        </extension>
        <strength value="required" />
        <description value="The mime type of an attachment. Any valid mime type is allowed." />
        <valueSet value="http://hl7.org/fhir/ValueSet/mimetypes" />
      </binding>
      <mapping>
        <identity value="rim" />
        <map value="ED.mediaType" />
      </mapping>
    </element>
    <element id="Binary.securityContext">
      <path value="Binary.securityContext" />
      <short value="Identifies another resource to use as proxy when enforcing access control" />
      <definition value="This element identifies another resource that can be used as a proxy of the security sensitivity to use when deciding and enforcing access control rules for the Binary resource. Given that the Binary resource contains very few elements that can be used to determine the sensitivity of the data and relationships to individuals, the referenced resource stands in as a proxy equivalent for this purpose. This referenced resource may be related to the Binary (e.g. DocumentReference), or may be some non-related Resource purely as a security proxy. E.g. to identify that the binary resource relates to a patient, and access should only be granted to applications that have access to the patient." />
      <comment value="Very often, a server will also know of a resource that references the binary, and can automatically apply the appropriate access rules based on that reference. However, there are some circumstances where this is not appropriate, e.g. the binary is uploaded directly to the server without any linking resource, the binary is referred to from multiple different resources, and/or the binary is content such as an application logo that has less protection than any of the resources that reference it." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="Reference" />
        <targetProfile value="http://hl7.org/fhir/StructureDefinition/Resource" />
      </type>
      <isSummary value="true" />
      <mapping>
        <identity value="rim" />
        <map value="n/a" />
      </mapping>
    </element>
    <element id="Binary.data">
      <path value="Binary.data" />
      <short value="The actual content" />
      <definition value="The actual content, base64 encoded." />
      <comment value="If the content type is itself base64 encoding, then this will be base64 encoded twice - what is created by un-base64ing the content must be the specified content type." />
      <min value="0" />
      <max value="1" />
      <type>
        <code value="base64Binary" />
      </type>
      <isSummary value="false" />
      <mapping>
        <identity value="rim" />
        <map value="ED.data" />
      </mapping>
    </element>
  </differential>
</StructureDefinition>