viral-load-diagnostic-report
type: StructureDefinition
node role: treeRoot
id:
  v: viral-load-diagnostic-report
text:
  status:
    v: extensions
  div: Generated Narrative: StructureDefinition viral-load-diagnostic-report Name Flags Card. Type Description & Constraints<img src="[binary]" alt="doco" style="background-color: inherit"/> DiagnosticReport 0..* DiagnosticReport A Diagnostic report - a combination of request information, atomic results, images, interpretation, as well as formatted reports #xD; meta 1..1 Meta Metadata about the resource #xD; Slices for security 1..* Coding Security Labels applied to this resource Slice: Unordered, Open by value:code #xD; security:VeryRestricted 1..1 Coding Security Labels applied to this resource #xD; system 1..1 uri Identity of the terminology system Required Pattern: http://terminology.hl7.org/CodeSystem/v3-Confidentiality #xD; code 1..1 code Symbol in syntax defined by the system Required Pattern: V #xD; basedOn 1..1 Reference(Service Request - PCR HIV Test) What was requested #xD; category 1..1 CodeableConcept Service category Required Pattern: At least the following #xD; coding 1..* Coding Code defined by a terminology system Fixed Value: (Complex) #xD; system 1..1 uri Identity of the terminology system Fixed Value: http://loinc.org #xD; code 1..1 code Symbol in syntax defined by the system Fixed Value: 11502-2 #xD; code 1..1 CodeableConcept Name/Code for this diagnostic report Required Pattern: At least the following #xD; coding 1..* Coding Code defined by a terminology system Fixed Value: (Complex) #xD; system 1..1 uri Identity of the terminology system Fixed Value: http://loinc.org #xD; code 1..1 code Symbol in syntax defined by the system Fixed Value: 25836-8 #xD; subject 1..1 Reference(Patient) The subject of the report - usually, but not always, the patient #xD; encounter 1..1 Reference(Encounter - Initiated By The Facility Providing the Service) Health care event when test ordered #xD; performer 1..1 Reference(Organization | Practitioner - General Practitioner) Responsible Diagnostic Service #xD; result 1..1 Reference(Observation - Viral Load Result) Observatio…
url:
  v: http://jembi.org/fhir/StructureDefinition/viral-load-diagnostic-report
version:
  v: 1.0.1
name:
  v: ViralLoadDiagnosticReport
title:
  v: Diagnostic Report - Viral Load
status:
  v: active
date:
  v: 2025-09-26T07:23:41+00:00
publisher:
  v: Jembi Health Systems
contact:
  name:
    v: Jembi Health Systems
  telecom:
    system:
      v: url
    value:
      v: https://www.jembi.org/
  telecom:
    system:
      v: email
contact:
  name:
    v: Richard Langford
  telecom:
    system:
      v: email
    use:
      v: work
description:
  v: Represents the results for viral load.
jurisdiction:
  coding:
    system:
      v: http://unstats.un.org/unsd/methods/m49/m49.htm
    code:
      v: 001
    display:
      v: World
fhir version:
  v: 4.0.1
mapping:
  identity:
    v: workflow
  uri:
    v: http://hl7.org/fhir/workflow
  name:
    v: Workflow Pattern
mapping:
  identity:
    v: v2
  uri:
    v: http://hl7.org/v2
  name:
    v: HL7 v2 Mapping
mapping:
  identity:
    v: rim
  uri:
    v: http://hl7.org/v3
  name:
    v: RIM Mapping
mapping:
  identity:
    v: w5
  uri:
    v: http://hl7.org/fhir/fivews
  name:
    v: FiveWs Pattern Mapping
kind:
  v: resource
abstract:
  v: false
type:
  v: DiagnosticReport
base definition:
  v: http://hl7.org/fhir/StructureDefinition/DiagnosticReport
  link: http://hl7.org/fhir/StructureDefinition/DiagnosticReport
derivation:
  v: constraint
snapshot:
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version
    value: string
      v: 4.0.1
  element:
    id:
      v: DiagnosticReport
    path:
      v: DiagnosticReport
    short:
      v: A Diagnostic report - a combination of request information, atomic results, images, interpretation, as well as formatted reports
    definition:
      v: The findings and interpretation of diagnostic tests performed on patients, groups of patients, devices, and locations, and/or specimens derived from these. The report includes clinical context such as requesting and provider information, and some mix of atomic results, images, textual and coded interpretations, and formatted representation of diagnostic reports.
    comment:
      v: This is intended to capture a single report and is not suitable for use in displaying summary information that covers multiple reports. For example, this resource has not been designed for laboratory cumulative reporting formats nor detailed structured reports for sequencing.
    alias:
      v: Report
    alias:
      v: Test
    alias:
      v: Result
    alias:
      v: Results
    alias:
      v: Labs
    alias:
      v: Laboratory
    min:
      v: 0
    max:
      v: *
    base:
      path:
        v: DiagnosticReport
      min:
        v: 0
      max:
        v: *
    constraint:
      key:
        v: dom-2
      severity:
        v: error
      human:
        v: If the resource is contained in another resource, it SHALL NOT contain nested Resources
      expression:
        v: contained.contained.empty()
      xpath:
        v: not(parent::f:contained and f:contained)
      source:
        v: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    constraint:
      key:
        v: dom-3
      severity:
        v: error
      human:
        v: If the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
      expression:
        v: contained.where((('#'+id in (%resource.descendants().reference | %resource.descendants().as(canonical) | %resource.descendants().as(uri) | %resource.descendants().as(url))) or descendants().where(reference = '#').exists() or descendants().where(as(canonical) = '#').exists() or descendants().where(as(canonical) = '#').exists()).not()).trace('unmatched', id).empty()
      xpath:
        v: not(exists(for $id in f:contained/*/f:id/@value return $contained[not(parent::*/descendant::f:reference/@value=concat('#', $contained/*/id/@value) or descendant::f:reference[@value='#'])]))
      source:
        v: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    constraint:
      key:
        v: dom-4
      severity:
        v: error
      human:
        v: If a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
      expression:
        v: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
      xpath:
        v: not(exists(f:contained/*/f:meta/f:versionId)) and not(exists(f:contained/*/f:meta/f:lastUpdated))
      source:
        v: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    constraint:
      key:
        v: dom-5
      severity:
        v: error
      human:
        v: If a resource is contained in another resource, it SHALL NOT have a security label
      expression:
        v: contained.meta.security.empty()
      xpath:
        v: not(exists(f:contained/*/f:meta/f:security))
      source:
        v: http://hl7.org/fhir/StructureDefinition/DomainResource
        link: http://hl7.org/fhir/StructureDefinition/DomainResource
    constraint:
      extension:
        value: boolean
      extension:
        value: markdown
      key:
        v: dom-6
      severity:
        v: warning
      human:
        v: A resource should have narrative for robust management
      expression:
        v: text.`div`.exists()
      xpath:
        v: exists(f:text/h:div)

boolean
v: true

markdown
v: When a resource has no narrative, only systems that fully understand the data can display the resource to a human safely. Including a human readable representation in the resource makes for a much more robust eco-system and cheaper handling of resources by intermediary systems. Some ecosystems restrict distribution of resources to only those systems that do fully understand the resources, and as a consequence implementers may believe that the narrative is superfluous. However experience shows that such eco-systems often open up to new participants over time.

v: false

v: false

identity:
  v: rim
map:
  v: Entity. Role, or Act

identity:
  v: workflow
map:
  v: Event

identity:
  v: v2
map:
  v: ORU -> OBR

identity:
  v: rim
map:
  v: Observation[classCode=OBS, moodCode=EVN]

id:
  v: DiagnosticReport.id
path:
  v: DiagnosticReport.id
short:
  v: Logical id of this artifact
definition:
  v: The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.
comment:
  v: The only time that a resource does not have an id is when it is being submitted to the server using a create operation.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    value: url
      v: id
  code:
    v: http://hl7.org/fhirpath/System.String
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta
path:
  v: DiagnosticReport.meta
short:
  v: Metadata about the resource
definition:
  v: The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: Resource.meta
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Meta
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta.id
path:
  v: DiagnosticReport.meta.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    value: url
      v: string
  code:
    v: http://hl7.org/fhirpath/System.String
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.meta.extension
path:
  v: DiagnosticReport.meta.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.meta.versionId
path:
  v: DiagnosticReport.meta.versionId
short:
  v: Version specific identifier
definition:
  v: The version specific identifier, as it appears in the version portion of the URL. This value changes when the resource is created, updated, or deleted.
comment:
  v: The server assigns this value, and ignores what the client specifies, except in the case that the server is imposing version integrity on updates/deletes.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Meta.versionId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta.lastUpdated
path:
  v: DiagnosticReport.meta.lastUpdated
short:
  v: When the resource version last changed
definition:
  v: When the resource last changed - e.g. when the version changed.
comment:
  v: This value is always populated except when the resource is first being created. The server / resource manager sets this value; what a client provides is irrelevant. This is equivalent to the HTTP Last-Modified and SHOULD have the same value on a [read](http://hl7.org/fhir/R4/http.html#read) interaction.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Meta.lastUpdated
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: instant
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta.source
path:
  v: DiagnosticReport.meta.source
short:
  v: Identifies where the resource comes from
definition:
  v: A uri that identifies the source system of the resource. This provides a minimal amount of [Provenance](http://hl7.org/fhir/R4/provenance.html#) information that can be used to track or differentiate the source of information in the resource. The source may identify another FHIR server, document, message, database, etc.
comment:
  v: In the provenance resource, this corresponds to Provenance.entity.what[x]. The exact use of the source (and the implied Provenance.entity.role) is left to implementer discretion. Only one nominated source is allowed; for additional provenance details, a full Provenance resource should be used. This element can be used to indicate where the current master source of a resource that has a canonical URL if the resource is no longer hosted at the canonical URL.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Meta.source
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta.profile
path:
  v: DiagnosticReport.meta.profile
short:
  v: Profiles this resource claims to conform to
definition:
  v: A list of profiles (references to [StructureDefinition](http://hl7.org/fhir/R4/structuredefinition.html#) resources) that this resource claims to conform to. The URL is a reference to [StructureDefinition.url](http://hl7.org/fhir/R4/structuredefinition-definitions.html#StructureDefinition.url).
comment:
  v: It is up to the server and/or other infrastructure of policy to determine whether/how these claims are verified and/or updated over time. The list of profile URLs is a set.
min:
  v: 0
max:
  v: *
base:
  path:
    v: Meta.profile
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/StructureDefinition|4.0.1
    link: 4.0
    link: .1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true

id:
  v: DiagnosticReport.meta.security
path:
  v: DiagnosticReport.meta.security
slicing:
  discriminator:
    type:
      v: value
    path:
      v: code
  description:
    v: Slicing meta.security based on the code value
  ordered:
    v: false
  rules:
    v: open
short:
  v: Security Labels applied to this resource
definition:
  v: reasons why this should be supported
comment:
  v: The security labels can be updated without changing the stated version of the resource. The list of security labels is a set. Uniqueness is based the system/code, and version and display are ignored.
min:
  v: 1
max:
  v: *
base:
  path:
    v: Meta.security
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Coding
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: SecurityLabels
  strength:
    v: extensible
  description:
    v: Security Labels from the Healthcare Privacy and Security Classification System.
  value set:
    v: http://hl7.org/fhir/ValueSet/security-labels|4.0.1
    link: 4.0
    link: .1

id:
  v: DiagnosticReport.meta.security:VeryRestricted
path:
  v: DiagnosticReport.meta.security
slice name:
  v: VeryRestricted
short:
  v: Security Labels applied to this resource
definition:
  v: Security labels applied to this resource. These tags connect specific resources to the overall security policy and infrastructure.
comment:
  v: The security labels can be updated without changing the stated version of the resource. The list of security labels is a set. Uniqueness is based the system/code, and version and display are ignored.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: Meta.security
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Coding
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: SecurityLabels
  strength:
    v: extensible
  description:
    v: Security Labels from the Healthcare Privacy and Security Classification System.
  value set:
    v: http://hl7.org/fhir/ValueSet/security-labels|4.0.1
    link: 4.0
    link: .1

id:
  v: DiagnosticReport.meta.security:VeryRestricted.id
path:
  v: DiagnosticReport.meta.security.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    value: url
      v: string
  code:
    v: http://hl7.org/fhirpath/System.String
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.meta.security:VeryRestricted.extension
path:
  v: DiagnosticReport.meta.security.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.meta.security:VeryRestricted.system
path:
  v: DiagnosticReport.meta.security.system
short:
  v: Identity of the terminology system
definition:
  v: The identification of the code system that defines the meaning of the symbol in the code.
comment:
  v: The URI may be an OID (urn:oid:...) or a UUID (urn:uuid:...). OIDs and UUIDs SHALL be references to the HL7 OID registry. Otherwise, the URI should come from HL7's list of FHIR defined special URIs or it should reference to some definition that establishes the system clearly and unambiguously.
requirements:
  v: Need to be unambiguous about the source of the definition of the symbol.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: Coding.system
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
pattern: uri
  v: http://terminology.hl7.org/CodeSystem/v3-Confidentiality
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: C*E.3
mapping:
  identity:
    v: rim
  map:
    v: ./codeSystem
mapping:
  identity:
    v: orim
  map:
    v: fhir:Coding.system rdfs:subPropertyOf dt:CDCoding.codeSystem

id:
  v: DiagnosticReport.meta.security:VeryRestricted.version
path:
  v: DiagnosticReport.meta.security.version
short:
  v: Version of the system - if relevant
definition:
  v: The version of the code system which was used when choosing this code. Note that a well-maintained code system does not need the version reported, because the meaning of codes is consistent across versions. However this cannot consistently be assured, and when the meaning is not guaranteed to be consistent, the version SHOULD be exchanged.
comment:
  v: Where the terminology does not clearly define what string should be used to identify code system versions, the recommendation is to use the date (expressed in FHIR date format) on which that version was officially published as the version date.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Coding.version
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: C*E.7
mapping:
  identity:
    v: rim
  map:
    v: ./codeSystemVersion
mapping:
  identity:
    v: orim
  map:
    v: fhir:Coding.version rdfs:subPropertyOf dt:CDCoding.codeSystemVersion

id:
  v: DiagnosticReport.meta.security:VeryRestricted.code
path:
  v: DiagnosticReport.meta.security.code
short:
  v: Symbol in syntax defined by the system
definition:
  v: A symbol in syntax defined by the system. The symbol may be a predefined code or an expression in a syntax defined by the coding system (e.g. post-coordination).
requirements:
  v: Need to refer to a particular code in the system.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: Coding.code
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
pattern: code
  v: V
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: C*E.1
mapping:
  identity:
    v: rim
  map:
    v: ./code
mapping:
  identity:
    v: orim
  map:
    v: fhir:Coding.code rdfs:subPropertyOf dt:CDCoding.code

id:
  v: DiagnosticReport.meta.security:VeryRestricted.display
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
  value: boolean
    v: true
path:
  v: DiagnosticReport.meta.security.display
short:
  v: Representation defined by the system
definition:
  v: A representation of the meaning of the code in the system, following the rules of the system.
requirements:
  v: Need to be able to carry a human-readable meaning of the code for readers that do not know the system.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Coding.display
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: C*E.2 - but note this is not well followed
mapping:
  identity:
    v: rim
  map:
    v: CV.displayName
mapping:
  identity:
    v: orim
  map:
    v: fhir:Coding.display rdfs:subPropertyOf dt:CDCoding.displayName

id:
  v: DiagnosticReport.meta.security:VeryRestricted.userSelected
path:
  v: DiagnosticReport.meta.security.userSelected
short:
  v: If this coding was chosen directly by the user
definition:
  v: Indicates that this coding was chosen by a user directly - e.g. off a pick list of available items (codes or displays).
comment:
  v: Amongst a set of alternatives, a directly chosen code is the most appropriate starting point for new translations. There is some ambiguity about what exactly 'directly chosen' implies, and trading partner agreement may be needed to clarify the use of this element and its consequences more completely.
requirements:
  v: This has been identified as a clinical safety criterium - that this exact system/code pair was chosen explicitly, rather than inferred by the system based on some rules or language processing.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Coding.userSelected
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: boolean
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: Sometimes implied by being first
mapping:
  identity:
    v: rim
  map:
    v: CD.codingRationale
mapping:
  identity:
    v: orim
  map:
    v: fhir:Coding.userSelected fhir:mapsTo dt:CDCoding.codingRationale. fhir:Coding.userSelected fhir:hasMap fhir:Coding.userSelected.map. fhir:Coding.userSelected.map a fhir:Map; fhir:target dt:CDCoding.codingRationale. fhir:Coding.userSelected\#true a [ fhir:source "true"; fhir:target dt:CDCoding.codingRationale\#O ]

id:
  v: DiagnosticReport.meta.tag
path:
  v: DiagnosticReport.meta.tag
short:
  v: Tags applied to this resource
definition:
  v: Tags applied to this resource. Tags are intended to be used to identify and relate resources to process and workflow, and applications are not required to consider the tags when interpreting the meaning of a resource.
comment:
  v: The tags can be updated without changing the stated version of the resource. The list of tags is a set. Uniqueness is based the system/code, and version and display are ignored.
min:
  v: 0
max:
  v: *
base:
  path:
    v: Meta.tag
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Coding
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: Tags
  strength:
    v: example
  description:
    v: Codes that represent various types of tags, commonly workflow-related; e.g. "Needs review by Dr. Jones".
  value set:
    v: http://hl7.org/fhir/ValueSet/common-tags|4.0.1
    link: 4.0
    link: .1

id:
  v: DiagnosticReport.implicitRules
path:
  v: DiagnosticReport.implicitRules
short:
  v: A set of rules under which this content was created
definition:
  v: A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc.
comment:
  v: Asserting this rule set restricts the content to be only understood by a limited set of trading partners. This inherently limits the usefulness of the data in the long term. However, the existing health eco-system is highly fractured, and not yet ready to define, collect, and exchange data in a generally computable sense. Wherever possible, implementers and/or specification writers should avoid using this element. Often, when used, the URL is a reference to an implementation guide that defines these special rules as part of it's narrative along with other profiles, value sets, etc.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.implicitRules
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: true
is modifier reason:
  v: This element is labeled as a modifier because the implicit rules may provide additional knowledge about the resource that modifies it's meaning or interpretation
is summary:
  v: true

id:
  v: DiagnosticReport.language
path:
  v: DiagnosticReport.language
short:
  v: Language of the resource content
definition:
  v: The base language in which the resource is written.
comment:
  v: Language is provided to support indexing and accessibility (typically, services such as text to speech use the language tag). The html language tag in the narrative applies to the narrative. The language tag on the resource may be used to specify the language of other presentations generated from the data in the resource. Not all the content has to be in the base language. The Resource.language should not be assumed to apply to the narrative automatically. If a language is specified, it should it also be specified on the div element in the html (see rules in HTML5 for information about the relationship between xml:lang and the html lang attribute).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.language
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-maxValueSet
    value: canonical
      v: http://hl7.org/fhir/ValueSet/all-languages
      link: http://hl7.org/fhir/ValueSet/all-languages
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: Language
  strength:
    v: preferred
  description:
    v: A human language.
  value set:
    v: http://hl7.org/fhir/ValueSet/languages|4.0.1
    link: 4.0
    link: .1

id:
  v: DiagnosticReport.text
path:
  v: DiagnosticReport.text
short:
  v: Text summary of the resource, for human interpretation
definition:
  v: A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.
comment:
  v: Contained resources do not have narrative. Resources that are not contained SHOULD have a narrative. In some cases, a resource may only have text with little or no additional discrete data (as long as all minOccurs=1 elements are satisfied). This may be necessary for data from legacy systems where information is captured as a "text blob" or where text is additionally entered raw or narrated and encoded information is added later.
alias:
  v: narrative
alias:
  v: html
alias:
  v: xhtml
alias:
  v: display
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DomainResource.text
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Narrative
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: Act.text?

id:
  v: DiagnosticReport.contained
path:
  v: DiagnosticReport.contained
short:
  v: Contained, inline Resources
definition:
  v: These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, and nor can they have their own independent transaction scope.
comment:
  v: This should never be done when the content can be identified properly, as once identification is lost, it is extremely difficult (and context dependent) to restore it again. Contained resources may have profiles and tags In their meta elements, but SHALL NOT have security labels.
alias:
  v: inline resources
alias:
  v: anonymous resources
alias:
  v: contained resources
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.contained
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Resource
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: DiagnosticReport.extension
path:
  v: DiagnosticReport.extension
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: DiagnosticReport.modifierExtension
path:
  v: DiagnosticReport.modifierExtension
short:
  v: Extensions that cannot be ignored
definition:
  v: May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://hl7.org/fhir/R4/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the resource that contains them
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: DiagnosticReport.identifier
path:
  v: DiagnosticReport.identifier
short:
  v: Business identifier for report
definition:
  v: Identifiers assigned to this report by the performer or other systems.
comment:
  v: Usually assigned by the Information System of the diagnostic service provider (filler id).
requirements:
  v: Need to know what identifier to use when making queries about this report from the source laboratory, and for linking to the report outside FHIR context.
alias:
  v: ReportID
alias:
  v: Filler ID
alias:
  v: Placer ID
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.identifier
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Identifier
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.identifier
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.identifier
mapping:
  identity:
    v: v2
  map:
    v: OBR-51/ for globally unique filler ID - OBR-3 , For non-globally unique filler-id the flller/placer number must be combined with the universal service Id - OBR-2(if present)+OBR-3+OBR-4
mapping:
  identity:
    v: rim
  map:
    v: id

id:
  v: DiagnosticReport.basedOn
path:
  v: DiagnosticReport.basedOn
short:
  v: What was requested
definition:
  v: Details concerning a service requested.
comment:
  v: Note: Usually there is one test request for each result, however in some circumstances multiple test requests may be represented using a single test result resource. Note that there are also cases where one request leads to multiple reports.
requirements:
  v: This allows tracing of authorization for the report and tracking whether proposals/recommendations were acted upon.
alias:
  v: Request
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.basedOn
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/vl-service-request
    link: http://jembi.org/fhir/StructureDefinition/vl-service-request
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: workflow
  map:
    v: Event.basedOn
mapping:
  identity:
    v: v2
  map:
    v: ORC? OBR-2/3?
mapping:
  identity:
    v: rim
  map:
    v: outboundRelationship[typeCode=FLFS].target

id:
  v: DiagnosticReport.status
path:
  v: DiagnosticReport.status
short:
  v: registered | partial | preliminary | final +
definition:
  v: The status of the diagnostic report.
requirements:
  v: Diagnostic services routinely issue provisional/incomplete reports, and sometimes withdraw previously released reports.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.status
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: code
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: true
is modifier reason:
  v: This element is labeled as a modifier because it is a status element that contains status entered-in-error which means that the resource should not be treated as valid
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: DiagnosticReportStatus
  strength:
    v: required
  description:
    v: The status of the diagnostic report.
  value set:
    v: http://hl7.org/fhir/ValueSet/diagnostic-report-status|4.0.1
    link: 4.0
    link: .1
mapping:
  identity:
    v: workflow
  map:
    v: Event.status
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.status
mapping:
  identity:
    v: v2
  map:
    v: OBR-25 (not 1:1 mapping)
mapping:
  identity:
    v: rim
  map:
    v: statusCode Note: final and amended are distinguished by whether observation is the subject of a ControlAct event of type "revise"

id:
  v: DiagnosticReport.category
path:
  v: DiagnosticReport.category
short:
  v: Service category
definition:
  v: A code that classifies the clinical discipline, department or diagnostic service that created the report (e.g. cardiology, biochemistry, hematology, MRI). This is used for searching, sorting and display purposes.
comment:
  v: Multiple categories are allowed using various categorization schemes. The level of granularity is defined by the category concepts in the value set. More fine-grained filtering can be performed using the metadata and/or terminology hierarchy in DiagnosticReport.code.
alias:
  v: Department
alias:
  v: Sub-department
alias:
  v: Service
alias:
  v: Discipline
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.category
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: CodeableConcept
pattern: CodeableConcept
  coding: https://loinc.org/rdf/11502-2
    system:
      v: http://loinc.org
    code:
      v: 11502-2
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: DiagnosticServiceSection
  strength:
    v: example
  description:
    v: Codes for diagnostic service sections.
  value set:
    v: http://hl7.org/fhir/ValueSet/diagnostic-service-sections|4.0.1
    link: 4.0
    link: .1
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.class
mapping:
  identity:
    v: v2
  map:
    v: OBR-24
mapping:
  identity:
    v: rim
  map:
    v: inboundRelationship[typeCode=COMP].source[classCode=LIST, moodCode=EVN, code < LabService].code

id:
  v: DiagnosticReport.code
path:
  v: DiagnosticReport.code
short:
  v: Name/Code for this diagnostic report
definition:
  v: A code or name that describes this diagnostic report.
alias:
  v: Type
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.code
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: CodeableConcept
pattern: CodeableConcept
  coding: https://loinc.org/rdf/25836-8
    system:
      v: http://loinc.org
    code:
      v: 25836-8
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: DiagnosticReportCodes
  strength:
    v: preferred
  description:
    v: Codes that describe Diagnostic Reports.
  value set:
    v: http://hl7.org/fhir/ValueSet/report-codes|4.0.1
    link: 4.0
    link: .1
mapping:
  identity:
    v: workflow
  map:
    v: Event.code
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.what[x]
mapping:
  identity:
    v: v2
  map:
    v: OBR-4 (HL7 v2 doesn't provide an easy way to indicate both the ordered test and the performed panel)
mapping:
  identity:
    v: rim
  map:
    v: code

id:
  v: DiagnosticReport.subject
path:
  v: DiagnosticReport.subject
short:
  v: The subject of the report - usually, but not always, the patient
definition:
  v: The subject of the report. Usually, but not always, this is a patient. However, diagnostic services also perform analyses on specimens collected from a variety of other sources.
requirements:
  v: SHALL know the subject context.
alias:
  v: Patient
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.subject
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Reference
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/test-patient
    link: http://jembi.org/fhir/StructureDefinition/test-patient
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.subject
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.subject[x]
mapping:
  identity:
    v: v2
  map:
    v: PID-3 (no HL7 v2 mapping for Group or Device)
mapping:
  identity:
    v: rim
  map:
    v: participation[typeCode=SBJ]
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.subject

id:
  v: DiagnosticReport.encounter
path:
  v: DiagnosticReport.encounter
short:
  v: Health care event when test ordered
definition:
  v: The healthcare event (e.g. a patient and healthcare provider interaction) which this DiagnosticReport is about.
comment:
  v: This will typically be the encounter the event occurred within, but some events may be initiated prior to or after the official completion of an encounter but still be tied to the context of the encounter (e.g. pre-admission laboratory tests).
requirements:
  v: Links the request to the Encounter context.
alias:
  v: Context
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.encounter
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Reference
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/target-facility-encounter
    link: http://jembi.org/fhir/StructureDefinition/target-facility-encounter
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.encounter
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.context
mapping:
  identity:
    v: v2
  map:
    v: PV1-19
mapping:
  identity:
    v: rim
  map:
    v: inboundRelationship[typeCode=COMP].source[classCode=ENC, moodCode=EVN]

id:
  v: DiagnosticReport.effective[x]
path:
  v: DiagnosticReport.effective[x]
short:
  v: Clinically relevant time/time-period for report
definition:
  v: The time or time-period the observed values are related to. When the subject of the report is a patient, this is usually either the time of the procedure or of specimen collection(s), but very often the source of the date/time is not known, only the date/time itself.
comment:
  v: If the diagnostic procedure was performed on the patient, this is the time it was performed. If there are specimens, the diagnostically relevant time can be derived from the specimen collection times, but the specimen information is not always available, and the exact relationship between the specimens and the diagnostically relevant time is not always automatic.
requirements:
  v: Need to know where in the patient history to file/present this report.
alias:
  v: Observation time
alias:
  v: Effective Time
alias:
  v: Occurrence
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DiagnosticReport.effective[x]
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: dateTime
type:
  code:
    v: Period
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.occurrence[x]
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.done[x]
mapping:
  identity:
    v: v2
  map:
    v: OBR-7
mapping:
  identity:
    v: rim
  map:
    v: effectiveTime

id:
  v: DiagnosticReport.issued
path:
  v: DiagnosticReport.issued
short:
  v: DateTime this version was made
definition:
  v: The date and time that this version of the report was made available to providers, typically after the report was reviewed and verified.
comment:
  v: May be different from the update time of the resource itself, because that is the status of the record (potentially a secondary copy), not the actual release time of the report.
requirements:
  v: Clinicians need to be able to check the date that the report was released.
alias:
  v: Date published
alias:
  v: Date Issued
alias:
  v: Date Verified
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DiagnosticReport.issued
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: instant
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.recorded
mapping:
  identity:
    v: v2
  map:
    v: OBR-22
mapping:
  identity:
    v: rim
  map:
    v: participation[typeCode=VRF or AUT].time

id:
  v: DiagnosticReport.performer
path:
  v: DiagnosticReport.performer
short:
  v: Responsible Diagnostic Service
definition:
  v: The diagnostic service that is responsible for issuing the report.
comment:
  v: This is not necessarily the source of the atomic data items or the entity that interpreted the results. It is the entity that takes responsibility for the clinical report.
requirements:
  v: Need to know whom to contact if there are queries about the results. Also may need to track the source of reports for secondary data analysis.
alias:
  v: Laboratory
alias:
  v: Service
alias:
  v: Practitioner
alias:
  v: Department
alias:
  v: Company
alias:
  v: Authorized by
alias:
  v: Director
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.performer
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/organization
    link: http://jembi.org/fhir/StructureDefinition/organization
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/practitioner
    link: http://jembi.org/fhir/StructureDefinition/practitioner
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.performer.actor
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.actor
mapping:
  identity:
    v: v2
  map:
    v: PRT-8 (where this PRT-4-Participation = "PO")
mapping:
  identity:
    v: rim
  map:
    v: .participation[typeCode=PRF]

id:
  v: DiagnosticReport.resultsInterpreter
path:
  v: DiagnosticReport.resultsInterpreter
short:
  v: Primary result interpreter
definition:
  v: The practitioner or organization that is responsible for the report's conclusions and interpretations.
comment:
  v: Might not be the same entity that takes responsibility for the clinical report.
requirements:
  v: Need to know whom to contact if there are queries about the results. Also may need to track the source of reports for secondary data analysis.
alias:
  v: Analyzed by
alias:
  v: Reported by
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.resultsInterpreter
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Practitioner|4.0.1
    link: 4.0
    link: .1
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/PractitionerRole|4.0.1
    link: 4.0
    link: .1
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Organization|4.0.1
    link: 4.0
    link: .1
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/CareTeam|4.0.1
    link: 4.0
    link: .1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Event.performer.actor
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.actor
mapping:
  identity:
    v: v2
  map:
    v: OBR-32, PRT-8 (where this PRT-4-Participation = "PI")
mapping:
  identity:
    v: rim
  map:
    v: .participation[typeCode=PRF]

id:
  v: DiagnosticReport.specimen
path:
  v: DiagnosticReport.specimen
short:
  v: Specimens this report is based on
definition:
  v: Details about the specimens on which this diagnostic report is based.
comment:
  v: If the specimen is sufficiently specified with a code in the test result name, then this additional data may be redundant. If there are multiple specimens, these may be represented per observation or group.
requirements:
  v: Need to be able to report information about the collected specimens on which the report is based.
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.specimen
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Specimen|4.0.1
    link: 4.0
    link: .1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: v2
  map:
    v: SPM
mapping:
  identity:
    v: rim
  map:
    v: participation[typeCode=SBJ]

id:
  v: DiagnosticReport.result
path:
  v: DiagnosticReport.result
short:
  v: Observations
definition:
  v: [Observations](http://hl7.org/fhir/R4/observation.html) that are part of this diagnostic report.
comment:
  v: Observations can contain observations.
requirements:
  v: Need to support individual results, or groups of results, where the result grouping is arbitrary, but meaningful.
alias:
  v: Data
alias:
  v: Atomic Value
alias:
  v: Result
alias:
  v: Atomic result
alias:
  v: Data
alias:
  v: Test
alias:
  v: Analyte
alias:
  v: Battery
alias:
  v: Organizer
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.result
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://jembi.org/fhir/StructureDefinition/viral-load-count-observation
    link: http://jembi.org/fhir/StructureDefinition/viral-load-count-observation
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: v2
  map:
    v: OBXs
mapping:
  identity:
    v: rim
  map:
    v: outboundRelationship[typeCode=COMP].target

id:
  v: DiagnosticReport.imagingStudy
path:
  v: DiagnosticReport.imagingStudy
short:
  v: Reference to full details of imaging associated with the diagnostic report
definition:
  v: One or more links to full details of any imaging performed during the diagnostic investigation. Typically, this is imaging performed by DICOM enabled modalities, but this is not required. A fully enabled PACS viewer can use this information to provide views of the source images.
comment:
  v: ImagingStudy and the image element are somewhat overlapping - typically, the list of image references in the image element will also be found in one of the imaging study resources. However, each caters to different types of displays for different types of purposes. Neither, either, or both may be provided.
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.imagingStudy
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Reference
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/ImagingStudy|4.0.1
    link: 4.0
    link: .1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: outboundRelationship[typeCode=COMP].target[classsCode=DGIMG, moodCode=EVN]

id:
  v: DiagnosticReport.media
path:
  v: DiagnosticReport.media
short:
  v: Key images associated with this report
definition:
  v: A list of key images associated with this report. The images are generally created during the diagnostic process, and may be directly of the patient, or of treated specimens (i.e. slides of interest).
requirements:
  v: Many diagnostic services include images in the report as part of their service.
alias:
  v: DICOM
alias:
  v: Slides
alias:
  v: Scans
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.media
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: v2
  map:
    v: OBX?
mapping:
  identity:
    v: rim
  map:
    v: outboundRelationship[typeCode=COMP].target

id:
  v: DiagnosticReport.media.id
path:
  v: DiagnosticReport.media.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
    value: url
      v: string
  code:
    v: http://hl7.org/fhirpath/System.String
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.media.extension
path:
  v: DiagnosticReport.media.extension
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: DiagnosticReport.media.modifierExtension
path:
  v: DiagnosticReport.media.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://hl7.org/fhir/R4/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
constraint:
  key:
    v: ext-1
  severity:
    v: error
  human:
    v: Must have either extensions or value[x], not both
  expression:
    v: extension.exists() != value.exists()
  xpath:
    v: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  source:
    v: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: DiagnosticReport.media.comment
path:
  v: DiagnosticReport.media.comment
short:
  v: Comment about the image (e.g. explanation)
definition:
  v: A comment about the image. Typically, this is used to provide an explanation for why the image is included, or to draw the viewer's attention to important features.
comment:
  v: The comment should be displayed with the image. It would be common for the report to include additional discussion of the image contents in other sections such as the conclusion.
requirements:
  v: The provider of the report should make a comment about each image included in the report.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DiagnosticReport.media.comment
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: .inboundRelationship[typeCode=COMP].source[classCode=OBS, moodCode=EVN, code="annotation"].value

id:
  v: DiagnosticReport.media.link
path:
  v: DiagnosticReport.media.link
short:
  v: Reference to the image source
definition:
  v: Reference to the image source.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: DiagnosticReport.media.link
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: Reference
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Media|4.0.1
    link: 4.0
    link: .1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: .value.reference

id:
  v: DiagnosticReport.conclusion
path:
  v: DiagnosticReport.conclusion
short:
  v: Clinical conclusion (interpretation) of test results
definition:
  v: Concise and clinically contextualized summary conclusion (interpretation/impression) of the diagnostic report.
requirements:
  v: Need to be able to provide a conclusion that is not lost among the basic result data.
alias:
  v: Report
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DiagnosticReport.conclusion
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: v2
  map:
    v: OBX
mapping:
  identity:
    v: rim
  map:
    v: inboundRelationship[typeCode="SPRT"].source[classCode=OBS, moodCode=EVN, code=LOINC:48767-8].value (type=ST)

id:
  v: DiagnosticReport.conclusionCode
path:
  v: DiagnosticReport.conclusionCode
short:
  v: Codes for the clinical conclusion of test results
definition:
  v: One or more codes that represent the summary conclusion (interpretation/impression) of the diagnostic report.
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.conclusionCode
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: CodeableConcept
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    value: string
      v: AdjunctDiagnosis
  strength:
    v: example
  description:
    v: Diagnosis codes provided as adjuncts to the report.
  value set:
    v: http://hl7.org/fhir/ValueSet/clinical-findings|4.0.1
    link: 4.0
    link: .1
mapping:
  identity:
    v: v2
  map:
    v: OBX
mapping:
  identity:
    v: rim
  map:
    v: inboundRelationship[typeCode=SPRT].source[classCode=OBS, moodCode=EVN, code=LOINC:54531-9].value (type=CD)

id:
  v: DiagnosticReport.presentedForm
path:
  v: DiagnosticReport.presentedForm
short:
  v: Entire report as issued
definition:
  v: Rich text representation of the entire result as issued by the diagnostic service. Multiple formats are allowed but they SHALL be semantically equivalent.
comment:
  v: "application/pdf" is recommended as the most reliable and interoperable in this context.
requirements:
  v: Gives laboratory the ability to provide its own fully formatted report for clinical fidelity.
min:
  v: 0
max:
  v: *
base:
  path:
    v: DiagnosticReport.presentedForm
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Attachment
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  xpath:
    v: @value|f:*|h:div
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: v2
  map:
    v: OBX
mapping:
  identity:
    v: rim
  map:
    v: text (type=ED)

element:
  id:
    v: DiagnosticReport
  path:
    v: DiagnosticReport
element:
  id:
    v: DiagnosticReport.meta
  path:
    v: DiagnosticReport.meta
  min:
    v: 1
element:
  id:
    v: DiagnosticReport.meta.security
  path:
    v: DiagnosticReport.meta.security
  slicing:
    discriminator:
      type:
        v: value
      path:
        v: code
    description:
      v: Slicing meta.security based on the code value
    ordered:
      v: false
    rules:
      v: open
  definition:
    v: reasons why this should be supported
  min:
    v: 1
element:
  id:
    v: DiagnosticReport.meta.security:VeryRestricted
  path:
    v: DiagnosticReport.meta.security
  slice name:
    v: VeryRestricted
  min:
    v: 1
  max:
    v: 1
element:
  id:
    v: DiagnosticReport.meta.security:VeryRestricted.system
  path:
    v: DiagnosticReport.meta.security.system
  min:
    v: 1
  pattern: uri
    v: http://terminology.hl7.org/CodeSystem/v3-Confidentiality
element:
  id:
    v: DiagnosticReport.meta.security:VeryRestricted.code
  path:
    v: DiagnosticReport.meta.security.code
  min:
    v: 1
  pattern: code
    v: V
element:
  id:
    v: DiagnosticReport.basedOn
  path:
    v: DiagnosticReport.basedOn
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: Reference
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/vl-service-request
      link: http://jembi.org/fhir/StructureDefinition/vl-service-request
element:
  id:
    v: DiagnosticReport.category
  path:
    v: DiagnosticReport.category
  min:
    v: 1
  max:
    v: 1
  pattern: CodeableConcept
    coding: https://loinc.org/rdf/11502-2
      system:
        v: http://loinc.org
      code:
        v: 11502-2
element:
  id:
    v: DiagnosticReport.code
  path:
    v: DiagnosticReport.code
  pattern: CodeableConcept
    coding: https://loinc.org/rdf/25836-8
      system:
        v: http://loinc.org
      code:
        v: 25836-8
element:
  id:
    v: DiagnosticReport.subject
  path:
    v: DiagnosticReport.subject
  min:
    v: 1
  type:
    code:
      v: Reference
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/test-patient
      link: http://jembi.org/fhir/StructureDefinition/test-patient
element:
  id:
    v: DiagnosticReport.encounter
  path:
    v: DiagnosticReport.encounter
  min:
    v: 1
  type:
    code:
      v: Reference
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/target-facility-encounter
      link: http://jembi.org/fhir/StructureDefinition/target-facility-encounter
element:
  id:
    v: DiagnosticReport.performer
  path:
    v: DiagnosticReport.performer
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: Reference
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/organization
      link: http://jembi.org/fhir/StructureDefinition/organization
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/practitioner
      link: http://jembi.org/fhir/StructureDefinition/practitioner
element:
  id:
    v: DiagnosticReport.result
  path:
    v: DiagnosticReport.result
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: Reference
    target profile:
      v: http://jembi.org/fhir/StructureDefinition/viral-load-count-observation
      link: http://jembi.org/fhir/StructureDefinition/viral-load-count-observation