ch-emed-quantity
type: StructureDefinition
node role: treeRoot
resource.id:
  value: ch-emed-quantity
domain resource.text:
  narrative.status:
    value: extensions
  narrative.div: Name Flags Card. Type Description & Constraints Quantity 0..* SimpleQuantity A fixed quantity (no comparator) value 1..1 decimal Numerical value (with implicit precision) unit 1..1 string Unit representation system 1..1 uri System of the code from Units of Presentation code 1..1 code Coded form of the unit Binding: UnitCode (required): The coded unit used describing the quantity. Documentation for this format
structure definition.url:
  value: http://fhir.ch/ig/ch-emed/StructureDefinition/ch-emed-quantity
structure definition.version:
  value: 1.0.0
structure definition.name:
  value: CHEMEDQuantityWithEmedUnits
structure definition.title:
  value: CH EMED Quantity with units
structure definition.status:
  value: active
structure definition.date:
  value: 2021-02-11
structure definition.publisher:
  value: eHealth Suisse
structure definition.contact:
  index: 0
  contact detail.name:
    value: eHealth Suisse
  contact detail.telecom:
    index: 0
    contact point.system:
      value: url
    contact point.value:
      value: https://www.e-health-suisse.ch/startseite.html
structure definition.description:
  value: A quantity with defined units
structure definition.jurisdiction:
  index: 0
  codeable concept.coding:
    index: 0
    coding.system:
      value: urn:iso:std:iso:3166
    coding.code:
      value: CH
structure definition.copyright:
  value: CC-BY-SA-4.0
structure definition.fhir version:
  value: 4.0.1
structure definition.mapping:
  index: 0
  structure definition.mapping.identity:
    value: cda
  structure definition.mapping.uri:
    value: http://hl7.org/v3/cda
  structure definition.mapping.name:
    value: CDA (R2)
structure definition.mapping:
  index: 1
  structure definition.mapping.identity:
    value: v2
  structure definition.mapping.uri:
    value: http://hl7.org/v2
  structure definition.mapping.name:
    value: HL7 v2 Mapping
structure definition.mapping:
  index: 2
  structure definition.mapping.identity:
    value: rim
  structure definition.mapping.uri:
    value: http://hl7.org/v3
  structure definition.mapping.name:
    value: RIM Mapping
structure definition.kind:
  value: complex-type
structure definition.abstract:
  value: false
structure definition.type:
  value: Quantity
structure definition.base definition:
  value: http://hl7.org/fhir/StructureDefinition/SimpleQuantity
  link: http://hl7.org/fhir/StructureDefinition/SimpleQuantity
structure definition.derivation:
  value: constraint
structure definition.snapshot:
  structure definition.snapshot.element:
    index: 0
    element.id:
      value: Quantity
    element definition.path:
      value: Quantity
    element definition.short:
      value: A fixed quantity (no comparator)
    element definition.definition:
      value: The comparator is not used on a SimpleQuantity
    element definition.comment:
      value: The context of use may frequently define what kind of quantity this is and therefore what kind of units can be used. The context of use may also restrict the values for the comparator.
    element definition.min:
      value: 0
    element definition.max:
      value: *
    element definition.base:
      element definition.base.path:
        value: Quantity
      element definition.base.min:
        value: 0
      element definition.base.max:
        value: *
    element definition.condition:
      value: ele-1
      index: 0
    element definition.constraint:
      index: 0
      element definition.constraint.key:
        value: ele-1
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: All FHIR elements must have a @value or children
      element definition.constraint.expression:
        value: hasValue() or (children().count() > id.count())
      element definition.constraint.xpath:
        value: @value|f:*|h:div
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/Element
        link: http://hl7.org/fhir/StructureDefinition/Element
    element definition.constraint:
      index: 1
      element definition.constraint.key:
        value: qty-3
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: If a code for the unit is present, the system SHALL also be present
      element definition.constraint.expression:
        value: code.empty() or system.exists()
      element definition.constraint.xpath:
        value: not(exists(f:code)) or exists(f:system)
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/Quantity
        link: http://hl7.org/fhir/StructureDefinition/Quantity
    element definition.constraint:
      index: 2
      element definition.constraint.key:
        value: sqty-1
      element definition.constraint.severity:
        value: error
      element definition.constraint.human:
        value: The comparator is not used on a SimpleQuantity
      element definition.constraint.expression:
        value: comparator.empty()
      element definition.constraint.xpath:
        value: not(exists(f:comparator))
      element definition.constraint.source:
        value: http://hl7.org/fhir/StructureDefinition/SimpleQuantity
        link: http://hl7.org/fhir/StructureDefinition/SimpleQuantity
    element definition.is modifier:
      value: false
    element definition.mapping:
      index: 0
      element definition.mapping.identity:
        value: rim
      element definition.mapping.map:
        value: n/a
    element definition.mapping:
      index: 1
      element definition.mapping.identity:
        value: v2
      element definition.mapping.map:
        value: SN (see also Range) or CQ
    element definition.mapping:
      index: 2
      element definition.mapping.identity:
        value: rim
      element definition.mapping.map:
        value: PQ, IVL<PQ>, MO, CO, depending on the values
  structure definition.snapshot.element:
    index: 1
    element.id:
      value: Quantity.id
    element definition.path:
      value: Quantity.id
    element definition.representation:
      value: xmlAttr
      index: 0
    element definition.short:
      value: Unique id for inter-element referencing
    element definition.definition:
      value: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
    element definition.min:
      value: 0
    element definition.max:
      value: 1
    element definition.base:
      element definition.base.path:
        value: Element.id
      element definition.base.min:
        value: 0
      element definition.base.max:
        value: 1
    element definition.type:
      index: 0
      element.extension:
        index: 0
      element definition.type.code:
        value: http://hl7.org/fhirpath/System.String

value: string

value: false

value: false

index: 0
element definition.mapping.identity:
  value: rim
element definition.mapping.map:
  value: n/a

index: 2
element.id:
  value: Quantity.extension
element definition.path:
  value: Quantity.extension
element definition.slicing:
  element definition.slicing.discriminator:
    index: 0
    element definition.slicing.discriminator.type:
      value: value
    element definition.slicing.discriminator.path:
      value: url
  element definition.slicing.description:
    value: Extensions are always sliced by (at least) url
  element definition.slicing.rules:
    value: open
element definition.short:
  value: Additional content defined by implementations
element definition.definition:
  value: 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.
element definition.comment:
  value: 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.
element definition.alias:
  value: extensions
  index: 0
element definition.alias:
  value: user content
  index: 1
element definition.min:
  value: 0
element definition.max:
  value: *
element definition.base:
  element definition.base.path:
    value: Element.extension
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: *
element definition.type:
  index: 0
  element definition.type.code:
    value: Extension
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.constraint:
  index: 1
  element definition.constraint.key:
    value: ext-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: Must have either extensions or value[x], not both
  element definition.constraint.expression:
    value: extension.exists() != value.exists()
  element definition.constraint.xpath:
    value: exists(f:extension)!=exists(f:*[starts-with(local-name(.), "value")])
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Extension
    link: http://hl7.org/fhir/StructureDefinition/Extension
element definition.is modifier:
  value: false
element definition.is summary:
  value: false
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: n/a

index: 3
element.id:
  value: Quantity.value
element definition.path:
  value: Quantity.value
element definition.short:
  value: Numerical value (with implicit precision)
element definition.definition:
  value: The value of the measured amount. The value includes an implicit precision in the presentation of the value.
element definition.comment:
  value: The implicit precision in the value should always be honored. Monetary values have their own rules for handling precision (refer to standard accounting text books).
element definition.requirements:
  value: Precision is handled implicitly in almost all cases of measurement.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Quantity.value
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: decimal
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: SN.2 / CQ - N/A
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: PQ.value, CO.value, MO.value, IVL.high or IVL.low depending on the value

index: 4
element.id:
  value: Quantity.comparator
element definition.path:
  value: Quantity.comparator
element definition.short:
  value: < | <= | >= | > - how to understand the value
element definition.definition:
  value: Not allowed to be used in this context
element definition.requirements:
  value: Need a framework for handling measures where the value is <5ug/L or >400mg/L due to the limitations of measuring methodology.
element definition.min:
  value: 0
element definition.max:
  value: 0
element definition.base:
  element definition.base.path:
    value: Quantity.comparator
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: code
element definition.meaning when missing:
  value: If there is no comparator, then there is no modification of the value
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: true
element definition.is modifier reason:
  value: This is labeled as "Is Modifier" because the comparator modifies the interpretation of the value significantly. If there is no comparator, then there is no modification of the value
element definition.is summary:
  value: true
element definition.binding:
  element.extension:
    index: 0
    extension.url:
      value: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
    extension.value string:
      value: QuantityComparator
  element definition.binding.strength:
    value: required
  element definition.binding.description:
    value: How the Quantity should be understood and represented.
  element definition.binding.value set:
    value: http://hl7.org/fhir/ValueSet/quantity-comparator|4.0.1
    link: 4.0
    link: .1
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: SN.1 / CQ.1
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: IVL properties

index: 5
element.id:
  value: Quantity.unit
element.extension:
  index: 0
  extension.url:
    value: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
  extension.value boolean:
    value: true
element definition.path:
  value: Quantity.unit
element definition.short:
  value: Unit representation
element definition.definition:
  value: A human-readable form of the unit.
element definition.requirements:
  value: There are many representations for units of measure and in many contexts, particular representations are fixed and required. I.e. mcg for micrograms.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Quantity.unit
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: string
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: (see OBX.6 etc.) / CQ.2
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: PQ.unit

index: 6
element.id:
  value: Quantity.system
element definition.path:
  value: Quantity.system
element definition.short:
  value: System of the code from Units of Presentation
element definition.definition:
  value: The identification of the system that provides the coded form of the unit.
element definition.requirements:
  value: Need to know the system that defines the coded form of the unit.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Quantity.system
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: uri
element definition.condition:
  value: qty-3
  index: 0
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: (see OBX.6 etc.) / CQ.2
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: CO.codeSystem, PQ.translation.codeSystem

index: 7
element.id:
  value: Quantity.code
element definition.path:
  value: Quantity.code
element definition.short:
  value: Coded form of the unit
element definition.definition:
  value: Units of Presentation
element definition.comment:
  value: The preferred system is UCUM, but SNOMED CT can also be used (for customary units) or ISO 4217 for currency. The context of use may additionally require a code from a particular system.
element definition.requirements:
  value: Need a computable form of the unit that is fixed across all forms. UCUM provides this for quantities, but SNOMED CT provides many units of interest.
element definition.min:
  value: 1
element definition.max:
  value: 1
element definition.base:
  element definition.base.path:
    value: Quantity.code
  element definition.base.min:
    value: 0
  element definition.base.max:
    value: 1
element definition.type:
  index: 0
  element definition.type.code:
    value: code
element definition.constraint:
  index: 0
  element definition.constraint.key:
    value: ele-1
  element definition.constraint.severity:
    value: error
  element definition.constraint.human:
    value: All FHIR elements must have a @value or children
  element definition.constraint.expression:
    value: hasValue() or (children().count() > id.count())
  element definition.constraint.xpath:
    value: @value|f:*|h:div
  element definition.constraint.source:
    value: http://hl7.org/fhir/StructureDefinition/Element
    link: http://hl7.org/fhir/StructureDefinition/Element
element definition.is modifier:
  value: false
element definition.is summary:
  value: true
element definition.binding:
  element definition.binding.strength:
    value: required
  element definition.binding.description:
    value: The coded unit used describing the quantity.
  element definition.binding.value set:
    value: http://fhir.ch/ig/ch-emed/ValueSet/UnitCode
    link: http://fhir.ch/ig/ch-emed/ValueSet/UnitCode
element definition.mapping:
  index: 0
  element definition.mapping.identity:
    value: v2
  element definition.mapping.map:
    value: (see OBX.6 etc.) / CQ.2
element definition.mapping:
  index: 1
  element definition.mapping.identity:
    value: rim
  element definition.mapping.map:
    value: PQ.code, MO.currency, PQ.translation.code

structure definition.differential.element:
  index: 0
  element.id:
    value: Quantity
  element definition.path:
    value: Quantity
  element definition.min:
    value: 0
  element definition.max:
    value: *
  element definition.is modifier:
    value: false
structure definition.differential.element:
  index: 1
  element.id:
    value: Quantity.value
  element definition.path:
    value: Quantity.value
  element definition.min:
    value: 1
structure definition.differential.element:
  index: 2
  element.id:
    value: Quantity.unit
  element definition.path:
    value: Quantity.unit
  element definition.min:
    value: 1
structure definition.differential.element:
  index: 3
  element.id:
    value: Quantity.system
  element definition.path:
    value: Quantity.system
  element definition.short:
    value: System of the code from Units of Presentation
  element definition.min:
    value: 1
structure definition.differential.element:
  index: 4
  element.id:
    value: Quantity.code
  element definition.path:
    value: Quantity.code
  element definition.definition:
    value: Units of Presentation
  element definition.min:
    value: 1
  element definition.binding:
    element definition.binding.strength:
      value: required
    element definition.binding.description:
      value: The coded unit used describing the quantity.
    element definition.binding.value set:
      value: http://fhir.ch/ig/ch-emed/ValueSet/UnitCode
      link: http://fhir.ch/ig/ch-emed/ValueSet/UnitCode