{
"description": "Abstract class defining the concept of relative quantified 'amounts'. For relative quantities, the `+` and `-` operators are defined (unlike descendants of `DV_ABSOLUTE_QUANTITY`, such as the date/time types). \\n",
"_filename": "StructureDefinition-DV-AMOUNT.json",
"package_name": "openehr.base",
"date": "2025-09-06T15:35:39+10:00",
"derivation": "specialization",
"publisher": "openEHR + HL7",
"fhirVersion": "5.0.0",
"jurisdiction": [ {
"coding": [ {
"code": "001",
"system": "http://unstats.un.org/unsd/methods/m49/m49.htm"
} ]
} ],
"name": "DV_AMOUNT",
"mapping": [ {
"uri": "http://hl7.org/v3",
"name": "RIM Mapping",
"identity": "rim"
} ],
"abstract": true,
"type": "http://openehr.org/fhir/StructureDefinition/DV_AMOUNT",
"experimental": "false",
"resourceType": "StructureDefinition",
"title": "DV_AMOUNT",
"package_version": "0.1.0-snapshot",
"extension": [ {
"url": "http://hl7.org/fhir/tools/StructureDefinition/web-source",
"valueUrl": "https://specifications.openehr.org/releases/RM/Release-1.1.0/data_types.html#_dv_amount_class"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#valid_percentage"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#add"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#subtract"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#is_equal"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#multiply"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#negative"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-operation",
"valueCanonical": "#less_than"
}, {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-wg",
"valueCode": "fhir"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/view-hint",
"valueCode": "element-view-as-leaf"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/view-hint",
"valueCode": "element-view-defns-parent"
}, {
"url": "http://hl7.org/fhir/tools/StructureDefinition/view-hint",
"valueCode": "element-view-replace-cardinality"
}, {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm",
"valueInteger": 3,
"_valueInteger": {
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical": "http://openehr.org/fhir/ImplementationGuide/openehr.base"
} ]
}
}, {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status",
"valueCode": "informative",
"_valueCode": {
"extension": [ {
"url": "http://hl7.org/fhir/StructureDefinition/structuredefinition-conformance-derivedFrom",
"valueCanonical": "http://openehr.org/fhir/ImplementationGuide/openehr.base"
} ]
}
} ],
"contained": [ {
"description": "Test whether a number is a valid percentage, i.e. between 0 and 100. ",
"system": false,
"instance": true,
"name": "valid_percentage",
"resourceType": "OperationDefinition",
"title": "valid_percentage",
"status": "active",
"id": "valid_percentage",
"kind": "operation",
"code": "valid_percentage",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "number",
"type": "Parameters"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "boolean"
} ]
}, {
"description": "Sum of this amount and another. The value of accuracy in the result is either:\n\n* the sum of the accuracies of the operands, if both present, or;\n* both operand accuracies are unknown_accuracy_value.\n\nIf the accuracy value is a percentage in one operand and not in the other, the form in the result is that of the larger operand.",
"system": false,
"instance": true,
"name": "add",
"resourceType": "OperationDefinition",
"title": "add",
"status": "active",
"id": "add",
"kind": "operation",
"code": "add",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "other",
"type": "Parameters"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "Parameters"
} ]
}, {
"description": "Difference of this amount and another. The value of `_accuracy_` in the result is either:\n\n* the sum of the accuracies of the operands, if both present, or;\n* unknown, if either or both operand accuracies are unknown.\n\nIf the `_accuracy_` value is a percentage in one operand and not in the other, the form in the result is that of the larger operand.",
"system": false,
"instance": true,
"name": "subtract",
"resourceType": "OperationDefinition",
"title": "subtract",
"status": "active",
"id": "subtract",
"kind": "operation",
"code": "subtract",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "other",
"type": "Parameters"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "Parameters"
} ]
}, {
"description": "Return True if this `DV_AMOUNT` is considered equal to `_other_`.",
"system": false,
"instance": true,
"name": "is_equal",
"resourceType": "OperationDefinition",
"title": "is_equal",
"status": "active",
"id": "is_equal",
"kind": "operation",
"code": "is_equal",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "other",
"type": "Parameters"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "boolean"
} ]
}, {
"description": "Product of this Amount and `_factor_`.",
"system": false,
"instance": true,
"name": "multiply",
"resourceType": "OperationDefinition",
"title": "multiply",
"status": "active",
"id": "multiply",
"kind": "operation",
"code": "multiply",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "factor",
"type": "decimal"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "Parameters"
} ]
}, {
"description": "Negated version of current object, such as used for representing a difference, e.g. a weight loss.",
"system": false,
"instance": true,
"name": "negative",
"resourceType": "OperationDefinition",
"title": "negative",
"status": "active",
"id": "negative",
"kind": "operation",
"code": "negative",
"parameter": [ {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "Parameters"
} ]
}, {
"description": "True if this object is less than `_other_`. Based on comparison of `_magnitude_`.",
"system": false,
"instance": true,
"name": "less_than",
"resourceType": "OperationDefinition",
"title": "less_than",
"status": "active",
"id": "less_than",
"kind": "operation",
"code": "less_than",
"parameter": [ {
"max": "1",
"min": 1,
"use": "in",
"name": "other",
"type": "Parameters"
}, {
"max": "1",
"min": 1,
"use": "out",
"name": "return",
"type": "boolean"
} ]
} ],
"snapshot": {
"element": [ {
"constraint": [ {
"key": "Other_reference_ranges_validity",
"human": "Other reference ranges validity must be present",
"source": "http://openehr.org/fhir/StructureDefinition/DV-ORDERED",
"severity": "error",
"expression": "other_reference_ranges.exists() implies other_reference_ranges.empty().not()"
}, {
"key": "Is_simple_validity",
"human": "Is simple validity must satisfy conditional constraints",
"source": "http://openehr.org/fhir/StructureDefinition/DV-ORDERED",
"severity": "error",
"expression": "(normal_range .empty() and other_reference_ranges .empty()) implies is_simple()"
}, {
"key": "Normal_range_and_status_consistency",
"human": "Normal range and status consistency must be present",
"source": "http://openehr.org/fhir/StructureDefinition/DV-ORDERED",
"severity": "error",
"expression": "(normal_range.exists() and normal_status.exists()) implies (normal_status.code_string.is_equal (āNā) xor normal_range.not().has (self))"
}, {
"key": "Magnitude_status_valid",
"human": "Magnitude status valid must be present",
"source": "http://openehr.org/fhir/StructureDefinition/DV-QUANTIFIED",
"severity": "error",
"expression": "magnitude_status.exists() implies valid_magnitude_status() (magnitude_status)"
}, {
"key": "Accuracy_is_percent_validity",
"human": "Accuracy is percent validity must satisfy conditional constraints",
"severity": "error",
"expression": "accuracy = 0 implies accuracy_is_percent.not()"
}, {
"key": "Accuracy_validity",
"human": "Accuracy validity must satisfy conditional constraints",
"severity": "error",
"expression": "accuracy_is_percent implies valid_percentage() (accuracy)"
} ],
"path": "DV_AMOUNT",
"min": 0,
"definition": "Abstract class defining the concept of relative quantified 'amounts'. For relative quantities, the `+` and `-` operators are defined (unlike descendants of `DV_ABSOLUTE_QUANTITY`, such as the date/time types). \n",
"isModifier": false,
"short": "Abstract class defining the concept of relative quantified 'amounts'.",
"mapping": [ {
"map": "n/a",
"identity": "rim"
} ],
"max": "*",
"id": "DV_AMOUNT",
"base": {
"max": "*",
"min": 0,
"path": "Base"
}
}, {
"path": "DV_AMOUNT.CR",
"min": 1,
"definition": "Carriage return character.",
"isModifier": false,
"short": "Carriage return character.",
"type": [ {
"code": "string"
} ],
"max": "1",
"id": "DV_AMOUNT.CR",
"base": {
"max": "1",
"min": 1,
"path": "BASIC_DEFINITIONS.CR"
}
}, {
"path": "DV_AMOUNT.LF",
"min": 1,
"definition": "Line feed character.",
"isModifier": false,
"short": "Line feed character.",
"type": [ {
"code": "string"
} ],
"max": "1",
"id": "DV_AMOUNT.LF",
"base": {
"max": "1",
"min": 1,
"path": "BASIC_DEFINITIONS.LF"
}
}, {
"path": "DV_AMOUNT.Local_terminology_id",
"min": 1,
"definition": "Predefined terminology identifier to indicate it is local to the knowledge resource in which it occurs, e.g. an archetype",
"isModifier": false,
"short": "Predefined terminology identifier",
"type": [ {
"code": "string"
} ],
"max": "1",
"id": "DV_AMOUNT.Local-terminology-id",
"base": {
"max": "1",
"min": 1,
"path": "OPENEHR_DEFINITIONS.Local_terminology_id"
}
}, {
"path": "DV_AMOUNT.normal_status",
"min": 0,
"definition": "Optional normal status indicator of value with respect to normal range for this value. Often included by lab, even if the normal range itself is not included. Coded by ordinals in series HHH, HH, H, (nothing), L, LL, LLL; see openEHR terminology group `normal_status`.",
"isModifier": false,
"short": "Optional normal status indicator of value with respect to normal range for this value.",
"type": [ {
"code": "http://openehr.org/fhir/StructureDefinition/CODE-PHRASE"
} ],
"max": "1",
"id": "DV_AMOUNT.normal-status",
"base": {
"max": "1",
"min": 0,
"path": "DV_ORDERED.normal_status"
}
}, {
"path": "DV_AMOUNT.normal_range",
"min": 0,
"definition": "Optional normal range.",
"isModifier": false,
"short": "Optional normal range.",
"type": [ {
"code": "http://openehr.org/fhir/StructureDefinition/DV-INTERVAL"
} ],
"max": "1",
"id": "DV_AMOUNT.normal-range",
"base": {
"max": "1",
"min": 0,
"path": "DV_ORDERED.normal_range"
}
}, {
"path": "DV_AMOUNT.other_reference_ranges",
"min": 0,
"definition": "Optional tagged other reference ranges for this value in its particular measurement context.",
"isModifier": false,
"short": "Optional tagged other reference ranges for this value in its particular measurement context.",
"type": [ {
"code": "http://openehr.org/fhir/StructureDefinition/REFERENCE-RANGE",
"extension": [ {
"url": "http://hl7.org/fhir/tools/StructureDefinition/type-parameter",
"extension": [ {
"url": "name",
"valueCode": "T"
}, {
"url": "type",
"valueUri": "http://openehr.org/fhir/StructureDefinition/DV-ORDERED"
} ]
} ]
} ],
"max": "*",
"id": "DV_AMOUNT.other-reference-ranges",
"base": {
"max": "*",
"min": 0,
"path": "DV_ORDERED.other_reference_ranges"
}
}, {
"path": "DV_AMOUNT.magnitude_status",
"min": 0,
"definition": "Optional status of magnitude with values: \n\n* `\"=\"` : magnitude is a point value \n* `\"<\"` : value is < magnitude \n* `\">\"` : value is > magnitude \n* `\"<=\"` : value is <= magnitude \n* `\">=\"` : value is >= magnitude \n* `\"~\"` : value is approximately magnitude \n\nIf not present, assumed meaning is `\"=\"` .",
"isModifier": false,
"short": "Optional status of magnitude with values: \n\n* `\"=\"` : magnitude is a point value \n* `\"<\"` : value is < magnitude \n* `\">\"` : value is > magnitude \n* `\"<=\"` : value is <= magnitude \n* `\">=\"` : value is >= magnitude \n* `\"~\"` : value is approximately magnitude \n\nIf not present, assumed meaning is `\"=\"` .",
"type": [ {
"code": "string"
} ],
"max": "1",
"id": "DV_AMOUNT.magnitude-status",
"base": {
"max": "1",
"min": 0,
"path": "DV_QUANTIFIED.magnitude_status"
}
}, {
"path": "DV_AMOUNT.accuracy",
"min": 0,
"definition": "Accuracy of measurement, expressed either as a half-range percent value (`_accuracy_is_percent_` = `True`) or a half-range quantity. A value of `0` means that accuracy is 100%, i.e. no error.\n\nA value of `_unknown_accuracy_value_` means that accuracy was not recorded.",
"isModifier": false,
"short": "Accuracy of measurement, expressed either as a half-range percent value (`_accuracy_is_percent_` = `True`) or a half-range quantity.",
"type": [ {
"code": "decimal"
} ],
"max": "1",
"id": "DV_AMOUNT.accuracy",
"base": {
"max": "1",
"min": 0,
"path": "DV_QUANTIFIED.accuracy"
}
}, {
"path": "DV_AMOUNT.accuracy_is_percent",
"min": 0,
"definition": "If `True`, indicates that when this object was created, `_accuracy_` was recorded as a percent value; if `False`, as an absolute quantity value.",
"isModifier": false,
"short": "If `True`, indicates that when this object was created, `_accuracy_` was recorded as a percent value; if `False`, as an absolute quantity value.",
"type": [ {
"code": "boolean"
} ],
"max": "1",
"id": "DV_AMOUNT.accuracy-is-percent",
"base": {
"max": "1",
"min": 0,
"path": "DV_AMOUNT.accuracy_is_percent"
}
} ],
"extension": [ {
"url": "http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version",
"valueString": "0.1.0-snapshot"
} ]
},
"status": "active",
"id": "63372708-6240-4ccd-bc6a-ae464827b3f8",
"kind": "logical",
"url": "http://openehr.org/fhir/StructureDefinition/DV-AMOUNT",
"version": "0.1.0-snapshot",
"differential": {
"element": [ {
"id": "DV_AMOUNT",
"max": "*",
"min": 0,
"path": "DV_AMOUNT",
"short": "Abstract class defining the concept of relative quantified 'amounts'.",
"constraint": [ {
"key": "Accuracy_is_percent_validity",
"human": "Accuracy is percent validity must satisfy conditional constraints",
"severity": "error",
"expression": "accuracy = 0 implies accuracy_is_percent.not()"
}, {
"key": "Accuracy_validity",
"human": "Accuracy validity must satisfy conditional constraints",
"severity": "error",
"expression": "accuracy_is_percent implies valid_percentage() (accuracy)"
} ],
"definition": "Abstract class defining the concept of relative quantified 'amounts'. For relative quantities, the `+` and `-` operators are defined (unlike descendants of `DV_ABSOLUTE_QUANTITY`, such as the date/time types). \n",
"isModifier": false
}, {
"id": "DV_AMOUNT.accuracy-is-percent",
"max": "1",
"min": 0,
"path": "DV_AMOUNT.accuracy_is_percent",
"type": [ {
"code": "boolean"
} ],
"short": "If `True`, indicates that when this object was created, `_accuracy_` was recorded as a percent value; if `False`, as an absolute quantity value.",
"definition": "If `True`, indicates that when this object was created, `_accuracy_` was recorded as a percent value; if `False`, as an absolute quantity value.",
"isModifier": false
}, {
"id": "DV_AMOUNT.accuracy",
"max": "1",
"min": 0,
"path": "DV_AMOUNT.accuracy",
"type": [ {
"code": "decimal"
} ],
"short": "Accuracy of measurement, expressed either as a half-range percent value (`_accuracy_is_percent_` = `True`) or a half-range quantity.",
"definition": "Accuracy of measurement, expressed either as a half-range percent value (`_accuracy_is_percent_` = `True`) or a half-range quantity. A value of `0` means that accuracy is 100%, i.e. no error.\n\nA value of `_unknown_accuracy_value_` means that accuracy was not recorded.",
"isModifier": false
} ]
},
"contact": [ {
"telecom": [ {
"value": "http://www.openehr.org",
"system": "url"
} ]
} ],
"baseDefinition": "http://openehr.org/fhir/StructureDefinition/DV-QUANTIFIED"
}