openEHR UML Model Release 1.0.1Printable


Dictionary    Diagrams

 am
 archetype
 ARCHETYPE
 VALIDITY_KIND
 assertion
 ASSERTION
 ASSERTION_VARIABLE
 EXPR_BINARY_OPERATOR
 EXPR_ITEM
 EXPR_LEAF
 EXPR_OPERATOR
 EXPR_UNARY_OPERATOR
 OPERATOR_KIND
 constraint_model
 ARCHETYPE_CONSTRAINT
 ARCHETYPE_INTERNAL_REF
 ARCHETYPE_SLOT
 C_ATTRIBUTE
 C_COMPLEX_OBJECT
 C_DEFINED_OBJECT
 C_DOMAIN_TYPE
 C_MULTIPLE_ATTRIBUTE
 C_OBJECT
 C_PRIMITIVE_OBJECT
 C_REFERENCE_OBJECT
 C_SINGLE_ATTRIBUTE
 CARDINALITY
 CONSTRAINT_REF
 primitive
 C_BOOLEAN
 C_DATE
 C_DATE_TIME
 C_DURATION
 C_INTEGER
 C_PRIMITIVE
 C_REAL
 C_STRING
 C_TIME
 VALIDITY_KIND
 ontology
 ARCHETYPE_ONTOLOGY
 ARCHETYPE_TERM
 openehr_profile
 data_types
 basic
 C_DV_STATE
 NON_TERMINAL_STATE
 STATE
 STATE_MACHINE
 TERMINAL_STATE
 TRANSITION
 quantity
 C_DV_ORDINAL
 C_DV_QUANTITY
 C_QUANTITY_ITEM
 text
 C_CODE_PHRASE
 template
 assumed_types
 Aggregate
 Array
 Hash
 Interval
 ISO8601_DATE
 ISO8601_DATE_TIME
 ISO8601_DURATION
 ISO8601_TIME
 ISO8601_TIMEZONE
 List
 Set
 String
 TIME_DEFINITIONS
 rm
 common
 archetyped
 ARCHETYPED
 FEEDER_AUDIT
 FEEDER_AUDIT_DETAILS
 LINK
 LOCATABLE
 PATHABLE
 change_control
 CONTRIBUTION
 IMPORTED_VERSION
 MERGED_VERSION
 ORIGINAL_VERSION
 VERSION
 VERSIONED_OBJECT
 directory
 FOLDER
 VERSIONED_FOLDER
 generic
 ATTESTATION
 AUDIT_DETAILS
 PARTICIPATION
 PARTY_IDENTIFIED
 PARTY_PROXY
 PARTY_RELATED
 PARTY_SELF
 REVISION_HISTORY
 REVISION_HISTORY_ITEM
 resource
 AUTHORED_RESOURCE
 RESOURCE_DESCRIPTION
 RESOURCE_DESCRIPTION_ITEM
 TRANSLATION_DETAILS
 composition
 COMPOSITION
 EVENT_CONTEXT
 content
 CONTENT_ITEM
 entry
 ACTION
 ACTIVITY
 ADMIN_ENTRY
 CARE_ENTRY
 ENTRY
 EVALUATION
 INSTRUCTION
 INSTRUCTION_DETAILS
 ISM_TRANSITION
 OBSERVATION
 navigation
 SECTION
 data_structures
 DATA_STRUCTURE
 history
 EVENT
 HISTORY
 INTERVAL_EVENT
 POINT_EVENT
 item_structure
 ITEM_LIST
 ITEM_SINGLE
 ITEM_STRUCTURE
 ITEM_TABLE
 ITEM_TREE
 representation
 CLUSTER
 ELEMENT
 ITEM
 data_types
 basic
 DATA_VALUE
 DV_BOOLEAN
 DV_IDENTIFIER
 DV_STATE
 encapsulated
 DV_ENCAPSULATED
 DV_MULTIMEDIA
 DV_PARSABLE
 quantity
 DV_ABSOLUTE_QUANTITY
 DV_AMOUNT
 DV_COUNT
 DV_INTERVAL<DV_DATE_TIME>
 DV_ORDERED
 DV_ORDINAL
 DV_PROPORTION
 DV_QUANTIFIED
 DV_QUANTITY
 PROPORTION_KIND
 REFERENCE_RANGE
 date_time
 DV_DATE
 DV_DATE_TIME
 DV_DURATION
 DV_INTERVAL
 DV_TEMPORAL
 DV_TIME
 text
 CODE_PHRASE
 DV_CODED_TEXT
 DV_PARAGRAPH
 DV_TEXT
 TERM_MAPPING
 time_specification
 DV_GENERAL_TIME_SPECIFICATION
 DV_PERIODIC_TIME_SPECIFICATION
 DV_TIME_SPECIFICATION
 uri
 DV_EHR_URI
 DV_URI
 demographic
 ACTOR
 ADDRESS
 AGENT
 CAPABILITY
 CONTACT
 GROUP
 ORGANISATION
 PARTY
 PARTY_IDENTITY
 PARTY_RELATIONSHIP
 PERSON
 ROLE
 VERSIONED_PARTY
 ehr
 EHR
 EHR_ACCESS
 EHR_STATUS
 VERSIONED_COMPOSITION
 VERSIONED_EHR_ACCESS
 VERSIONED_EHR_STATUS
 integration
 GENERIC_ENTRY
 security
 access_control
 support
 EXTERNAL_ENVIRONMENT_ACCESS
 definition
 BASIC_DEFINITIONS
 OPENEHR_DEFINITIONS
 identification
 ACCESS_GROUP_REF
 ARCHETYPE_ID
 GENERIC_ID
 HIER_OBJECT_ID
 INTERNET_ID
 ISO_OID
 LOCATABLE_REF
 OBJECT_ID
 OBJECT_REF
 OBJECT_VERSION_ID
 PARTY_REF
 TEMPLATE_ID
 TERMINOLOGY_ID
 UID
 UID_BASED_ID
 UUID
 VERSION_TREE_ID
 measurement
 MEASUREMENT_SERVICE
 terminology
 CODE_SET_ACCESS
 OPENEHR_TERMINOLOGY_CODE_SET_IDENTIFIERS
 OPENEHR_TERMINOLOGY_GROUP_IDENTIFIERS
 TERMINOLOGY_ACCESS
 TERMINOLOGY_SERVICE
 sm
 BINARY_QUERY_NODE
 QUERY
 QUERY_ITEM
 QUERY_LEAF
 QUERY_NODE
 UNARY_QUERY_NODE
 TypesUML
 Any
 Date
 Date_Time
 Duration
 DV_INTERVAL<DV_DATE>
 Hash<String,String>
 Hash<TRANSLATION_DETAILS, String>
 Interval<Date_Time>
 Interval<Date>
 Interval<Duration>
 Interval<Integer>
 Interval<Real>
 Interval<Time>
 List<Any>
 List<C_OBJECT>
 List<DV_TEXT>
 List<ELEMENT>
 List<PARTICIPATION>
 List<String>
 List<VERSION>
 Set<CODE_PHRASE>
 Set<Integer>
 Set<Real>
 Set<String>
 T
 Time
 U
 Any
 Array<Octet>
 Boolean
 Character
 Double
 Integer
 Interval<T>
 List<ASSERTION>
 List<CLUSTER>
 List<DV_IDENTIFIER>
 List<OBJECT_REF>
 List<OBJECT_VERSION_ID>
 List<REFERENCE_RANGE>
 Numeric
 Octet
 Ordered
 Ordered_Numeric
 Real
 Set<DV_EHR_URI>
 Set<LOCATABLE_REF>
 Set<OBJECT_VERSION_ID>
 Set<PARTY_REF>
 String
Diagrams
 am.archetype
 am.archetype.assertion
 am.archetype.constraint_model
 am.archetype.constraint_model.primitive
 am.archetype.ontology
 am.openehr_profile
 am.openehr_profile.data_types.basic
 am.openehr_profile.data_types.quantity
 am.openehr_profile.data_types.text
 am.packages
 am.packages_with_classes
 assumed_library_types
 assumed_types
 assumed_types_date_time
 assumed_types_date_time_summary
 assumed_types_primitive_detailed
 assumed_types_primitive_outline
 overall.packages
 rm.common.archetyped
 rm.common.change_control
 rm.common.directory
 rm.common.generic
 rm.common.packages
 rm.common.resource
 rm.composition
 rm.composition.content
 rm.composition.content.entry
 rm.composition.content.navigation
 rm.data_structures
 rm.data_structures.history
 rm.data_structures.item_structure
 rm.data_structures.representation
 rm.data_types
 rm.data_types.basic
 rm.data_types.encapsulated
 rm.data_types.quantity
 rm.data_types.quantity.date_time
 rm.data_types.text
 rm.data_types.time_specification
 rm.data_types.uri
 rm.demographic
 rm.ehr
 rm.entry.observation_reduced
 rm.integration
 rm.packages
 rm.Packages_with_Classes
 rm.security
 rm.support
 rm.support.definition
 rm.support.identification
 rm.support.measurement
 rm.support.terminology
 sm.EHR_Client_API


Package :: am


Inner Elements
NameType
 archetypePackage
 openehr_profilePackage
 templatePackage


Parent Package: am
Package :: archetype

The model of an archetype is straightforward at an abstract level, mimicking the structure of an archetype document as defined in the openEHR Archetype Definition Language (ADL) document. An archetype is a modelled as a particular kind of AUTHORED_RESOURCE, and as such, includes descriptive meta-data, language information and revision history. The ARCHETYPE class adds identifying information, a definition - expressed in terms of constraints on instances of an object model, and an ontology. The archetype definition, the ‘main’ part of an archetype, is an instance of a C_COMPLEX_OBJECT, which is to say, the root of the constraint structure of an archetype always takes the form of a constraint on a non-primitive object type. The last section of an archetype, the ontology, is represented by its own class, and is what allows the archetypes to be natural language-and terminology-neutral. A utility class, VALIDITY_KIND is also included in the Archetype package. This class contains one integer attribute and three constant definitions, and is intended to be used as the type of any attribute in this constraint model whose value is logically ‘mandatory’, ‘optional’, or ‘disallowed’. It is used in this model in the classes C_Date, C_Time and C_Date_Time.


Inner Elements
NameType
 ARCHETYPEClass
 VALIDITY_KINDClass
 assertionPackage
 constraint_modelPackage
 ontologyPackage


Parent Package: archetype
Class ARCHETYPE


AUTHORED_RESOURCE
   |
   +--ARCHETYPE

Archetype equivalent to ARCHETYPED class in Common reference model. Defines semantics of identfication, lifecycle, versioning, composition and specialisation.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 adl_version : String 0..1  --   
 archetype_id : ARCHETYPE_ID  --  Multi-axial identifier of this archetype in archetype space. 
 concept : String  --  The normative meaning of the archetype as a whole, expressed as a local archetype code, typically “at0000”. 
 parent_archetype_id : ARCHETYPE_ID 0..1  --  Identifier of the specialisation parent of this archetype. 
 uid : HIER_OBJECT_ID 0..1  --  OID identifier of this archetype. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 definition : C_COMPLEX_OBJECT -- Root node of this archetype 
 ontology : ARCHETYPE_ONTOLOGY -- The ontology of the archetype. 
 invariants : Set<ASSERTION>0..1   

Operations
SignatureConstraintsDocumentation
 concept_name(a_lang : String) : String  The concept name of the archetype in language. a_lang; corresponds to the term definition of the concept_code attribute in the archetype tology. 
 constraint_references_valid() : Boolean  True if every CONSTRAINT_REF.reference found on a C_OBJECT node in the archetype definition is found in ontology. constraint_codes. 
 internal_references_valid() : Boolean  True if every ARCHETYPE_INTERNAL_REF. target_path refers to a legitimate node in the archetype definition. 
 is_specialised() : Boolean  True if this archetype is a specialisation of another. 
 is_valid() : Boolean  True if the archetype is valid overall; various tests should be used, including checks on node_ids, internal references, and constraint references. 
 logical_paths(a_lang : String) : Set<String>  Set of language-dependent paths extracted from archetype. Paths obey the same syntax as physical_paths, but with node_ids replaced by their meanings from the ontology. 
 node_ids_valid() : Boolean  True if every node_id found on a C_OBJECT node is found in ontology.term_codes. 
 physical_paths() : Set<String>  Set of language-independent paths extracted from archetype. Paths obey Xpath-like syntax and are formed from alternations of C_OBJECT.node_id and C_ATTRIBUTE.rm_attribute_name values. 
 previous_version() : String  Version of predecessor archetype of this archetype, if any. 
 short_concept_name() : String  The short concept name of the archetype extracted from the archetype_id. 
 specialisation_depth() : Integer  Specialisation depth of this archetype; larger than 0 if this archetype has a parent. Derived from ontology.specialisation_depth. 
 version() : String  Version of this archetype, extracted from id. 

Constraints
NameExpression
revision_history_validityinv: is_controlled implies (revision_history <> Void and revision_history.is_empty) 
archetype_id_validityinv: archetype_id <> Void 
description_existsinv: description <> Void 
ontology_existsinv: ontology <> Void 
definition_existsinv: definition <> Void 
uid_validityinv: uid <> Void implies not uid.is_empty 
original_language_validinv: original_language <>void and language <> Void and code_set(Code_set_id_languages).has_code(original_language) 
version_validityinv:version <> Void and version.is_equal(archetype_id.version_id) 
has_parentpost: is_specialised implies parent_archetype_id <>Void 
invariants_validinv: invariants <> Void implies not invariants.is_empty 
concept_validinv: ontology.has_term_code(concept_code) 
Specialisation_validityinv: is_specialised implies specialisation_depth > 0 


Parent Package: archetype
Class VALIDITY_KIND

An enumeration of three values which may commonly occur in constraint models.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 disallowed : Integer 0..1  -- 1003 Constant to indicate disallowed presence of something 
 mandatory : Integer 0..1  -- 1001 Constant to indicate mandatory presence of something 
 optional : Integer 0..1  -- 1002 Constant to indicate optional presence of something 
 value : Integer 0..1  --  Actual value 

Operations
SignatureConstraintsDocumentation
 valid_validity(a_validity : Integer) : Boolean 
post: a_validity >= mandatory and a_validity <= disallowed  
Function to test validity values. 

Constraints
NameExpression
Validityinv: valid_validity(value) 


Parent Package: archetype
Package :: assertion

Assertions are expressed in archetypes in typed first-order predicate logic (FOL). They are used in two places: to express archetype slot constraints, and to express invariants in complex object constraints. In both of these places, their role is to constrain something inside the archetype. Constraints on external resources such as terminologies are expressed in the constraint binding part of the archetype ontology, described in the Ontology Package The concrete syntax of assertion statements in archetypes is designed to be compatible with the OMG Object Constraint Language (OCL). Archetype assertions are essentially statements that contain the following elements: • variables, which are attribute names, or ADL paths terminating in attribute names (i.e. equivalent of referencing class feature in a programming language); • manifest constants of any primitive type, plus date/time types • arithmetic operators: +, *, -, /, ^ (exponent) • relational operators: >, <, >=, <=, =, !=, matches • Boolean operators: not, and, or, xor • quantifiers applied to container variables: for_all, exists The package described here is currently designed to allow the representation of a general-purpose binary expression tree, as would be generated by a parser. This may be replaced in the future by a more specific model, if needed.


Inner Elements
NameType
 ASSERTIONClass
 ASSERTION_VARIABLEClass
 EXPR_BINARY_OPERATORClass
 EXPR_ITEMClass
 EXPR_LEAFClass
 EXPR_OPERATORClass
 EXPR_UNARY_OPERATORClass
 OPERATOR_KINDClass


Parent Package: assertion
Class EXPR_ITEM{Abstract}

Direct Subclassifiers:
       EXPR_LEAF, EXPR_OPERATOR

Abstract parent of all expression tree items.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 type : String  --  Type name of this item. For leaf nodes, must be the name of a primitive type, or else a reference model type. The type for any relational or boolean operator will be “BOOLEAN”, while the type for any arithmetic operator, will be “REAL” or “INTEGER” 

Constraints
NameExpression
type_validinv: type <> Void and not type.is_empty 


Parent Package: assertion
Class EXPR_LEAF


EXPR_ITEM
   |
   +--EXPR_LEAF

Expression tree leaf item


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 item : Any  --  The value referred to; a manifest constant, an attribute path, or a C_PRIMITIVE. [Future: possibly function names as well, even if not constrained in the archetype - as long as they are in the reference model]. 
 reference_type : String  --  Type of reference: “constant”, “attribute”, “function” 

Constraints
NameExpression
item_validinv: item <> Void 


Parent Package: assertion
Class EXPR_OPERATOR{Abstract}


EXPR_ITEM
   |
   +--EXPR_OPERATOR

Direct Subclassifiers:
       EXPR_BINARY_OPERATOR, EXPR_UNARY_OPERATOR

Abstract parent of operator types.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 operator :   --  Code of operator. 
 precedence_overridden : Boolean 0..1  --  True if the natural precedence of operators is overridden in the expression represented by this node of the expression tree. If True, parentheses should be introduced around the totality of the syntax expression corresponding to this operator node and its operands. 


Parent Package: assertion
Class EXPR_UNARY_OPERATOR


EXPR_OPERATOR
   |
   +--EXPR_UNARY_OPERATOR

Unary operator expression node.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 operand : EXPR_ITEM -- Operand node. 

Constraints
NameExpression
operand_validinv: operand <> Void 


Parent Package: assertion
Class EXPR_BINARY_OPERATOR


EXPR_OPERATOR
   |
   +--EXPR_BINARY_OPERATOR

Binary operator expression node.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 left_operand : EXPR_ITEM -- Left operand node. 
 right_operand : EXPR_ITEM -- Right operand node. 

Constraints
NameExpression
left_operand_validinv: left_operand <> Void 
right_operand_validinv: right_operand <> Void 


Parent Package: assertion
Class ASSERTION_VARIABLE

Definition of a named variable used in an assertion expression. Note: the definition of named variables may change; still under development in ADL2.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 definition : String  --  Formal definition of the variable. (see ADL2 specification; still under development). 
 name : String  --  Name of variable. 

Constraints
NameExpression
Definition_validinv: definition <> Void and not definition.is_empty 
Name_validinv: name <> Void and not name.is_empty  


Parent Package: assertion
Class ASSERTION

Structural model of a typed first order predicate logic assertion, in the form of an expression tree, including optional variable definitions.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 string_expression : String  --  String form of expression, in case an expression evaluator taking String expressions is used for evaluation. 
 tag : String 0..1  --  Expression tag, used for differentiating multiple assertions. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 variables : List<ASSERTION_VARIABLE>0..1 0..* orderedDefinitions of variables used in the assertion expression. 
 expression : EXPR_ITEM -- Root of expression tree. 

Constraints
NameExpression
expression_validinv: expression <> Void and expression.type.is_equal('Boolean') 
tag_validinv: tag <> Void implies not tag.is_empty 


Parent Package: assertion
Class OPERATOR_KIND

Enumeration type for operator types in assertion expressions


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 op_and : Integer 0..1  -- 2011 And logical operator 
 op_divide : Integer 0..1  -- 2023 Divide operator (‘/’) 
 op_eq : Integer 0..1  -- 2001 Equals operator (‘=’ or ‘==’) 
 op_exists : Integer 0..1  -- 2016 Exists quantifier operator 
 op_exp : Integer 0..1  -- 2024 Exponent operator (‘^’) 
 op_for_all : Integer 0..1  -- 2015 For-all quantifier operator 
 op_ge : Integer 0..1  -- 2005 Greater-than or equals operator (‘>=’) 
 op_gt : Integer 0..1  -- 2006 Greater-than operator (‘>’) 
 op_implies : Integer 0..1  -- 2014 Implies logical operator 
 op_le : Integer 0..1  -- 2003 Less-than or equals operator (‘<=’) 
 op_lt : Integer 0..1  -- 2004 Less-than operator (‘<’) 
 op_matches : Integer 0..1  -- 2007 Matches operator (‘matches’ or ‘is_in’) 
 op_minus : Integer 0..1  -- 2021 Minus operator (‘-’) 
 op_multiply : Integer 0..1  -- 2022 Multiply operator (‘*’) 
 op_ne : Integer 0..1  -- 2002 Not equals operator (‘!=’ or ‘/=’ or ‘<>’) 
 op_not : Integer 0..1  -- 2010 Not logical operator 
 op_or : Integer 0..1  -- 2012 Or logical operator 
 op_plus : Integer 0..1  -- 2020 Plus operator (‘+’) 
 op_xor : Integer 0..1  -- 2013 Xor logical operator 
 value : Integer 0..1  --  Actual value of this instance 

Operations
SignatureConstraintsDocumentation
 valid_operator(an_op : Integer) : Boolean 
post:an_op >= op_eq and an_op <= op_exp  
Function to test operator values. 

Constraints
NameExpression
validityinv: valid_operator(value) 


Parent Package: archetype
Package :: constraint_model

The following statements summarise the main features of this package. Any archetype definition is an instance of a C_COMPLEX_OBJECT, which can be thought of as expressing constraints on a object that is of some particular type (recorded in the attribute rm_type_name ) in a reference model, and which is larger than a simple instance of a primitive type such as String or Integer. A C_COMPLEX_OBJECT consists of attributes of type C_ATTRIBUTE, which are constraints on the attributes (i.e. any property, including relationships) of the reference model type. Accordingly, each C_ATTRIBUTE records the name of the constrained attribute (in rm_attr_name), the existence and cardinality expressed by the constraint (depending on whether the attribute it constrains is a multiple or single relationship), and the constraint on the object to which this C_ATTRIBUTE refers via its children attribute (according to its reference model) in the form of further C_OBJECTs. The key subtypes of C_OBJECT, are C_COMPLEX_OBJECT (described above) C_PRIMITIVE_OBJECT (constraints on instances of primitive types such as String, Integer, Boolean and Date). The other subtypes of C_OBJECT, namely, ARCHETYPE_SLOT, ARCHETYPE_INTERNAL_REF and CONSTRAINT_REF are used to express, respectively, a `slot' where further archetypes can be used to continue describing constraints; a reference to a part of the current archetype that expresses exactly the same constraints needed at another point; and a reference to a constraint on a constraint defined in the archetype ontology, which in turn points to an external knowledge resource, such as a terminology. All nodes in an archetype constraint structure are instances of the supertype ARCHETYPE_CONSTRAINT, which provides a number of important common features to all nodes.


Inner Elements
NameType
 ARCHETYPE_CONSTRAINTClass
 ARCHETYPE_INTERNAL_REFClass
 ARCHETYPE_SLOTClass
 C_ATTRIBUTEClass
 C_COMPLEX_OBJECTClass
 C_DEFINED_OBJECTClass
 C_DOMAIN_TYPEClass
 C_MULTIPLE_ATTRIBUTEClass
 C_OBJECTClass
 C_PRIMITIVE_OBJECTClass
 C_REFERENCE_OBJECTClass
 C_SINGLE_ATTRIBUTEClass
 CARDINALITYClass
 CONSTRAINT_REFClass
 primitivePackage


Parent Package: constraint_model
Class ARCHETYPE_CONSTRAINT{Abstract}

Direct Subclassifiers:
       C_ATTRIBUTE, C_OBJECT

Archetype equivalent to LOCATABLE class in openEHR Common reference model. Defines common constraints for any inheritor of LOCATABLE in any reference model.


Operations
SignatureConstraintsDocumentation
 has_path(a_path : String) : Boolean 
pre: a_path <> Void  
True if the relative path a_path exists at this node. 
 is_subset_of(other : ARCHETYPE_CONSTRAINT) : Boolean 
pre: other <> Void  
True if constraints represented by other are narrower than this node. 
 is_valid() : Boolean  True if this node (and all its sub-nodes) is a valid archetype node for its type. This function should be implemented by each subtype to perform semantic validation of itself, and then call the is_valid function in any subparts, and generate the result appropriately. 
 path() : String  Path of this node relative to root of archetype. 

Constraints
NameExpression
path_existsinv: path <> Void 


Parent Package: constraint_model
Class C_ATTRIBUTE{Abstract}


ARCHETYPE_CONSTRAINT
   |
   +--C_ATTRIBUTE

Direct Subclassifiers:
       C_MULTIPLE_ATTRIBUTE, C_SINGLE_ATTRIBUTE

Abstract model of constraint on any kind of attribute node.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 existence : Interval<Integer>  --  Constraint on every attribute, regardless of whether it is singular or of a container type, which indicates whether its target object exists or not (i.e. is mandatory or not). 
 rm_attribute_name : String  --  Reference model attribute within the enclosing type represented by a C_OBJECT . 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 children : Set<C_OBJECT>0..1 Child C_OBJECT nodes. Each such node represents a constraint on the type of this attribute in its reference model. Multiples occur both for multiple items in the case of container attributes, and alternatives in the case of singular attributes. 

Constraints
NameExpression
existence_setinv: existence <> Void and (existence.lower >= 0 and existence.upper <= 1) 
rm_attribute_name_validinv: rm_attribute_name <> Void and not rm_attribute_name.is_empty 
children_validityinv: any_allowed xor children <> Void 


Parent Package: constraint_model
Class C_OBJECT{Abstract}


ARCHETYPE_CONSTRAINT
   |
   +--C_OBJECT

Direct Subclassifiers:
       C_DEFINED_OBJECT, C_REFERENCE_OBJECT

Abstract model of constraint on any kind of object node.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 node_id : String  --  Semantic id of this node, used to differentiate sibling nodes of the same type. [Previously called `meaning']. Each node_id must be defined in the archetype ontology as a term code. 
 occurrences : Interval<Integer>  --  Occurrences of this object node in the data, under the owning attribute. Upper limit can only be greater than 1 if owning attribute has a cardinality of more than 1). 
 rm_type_name : String  --  Reference model type that this node corresponds to. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 parent : C_ATTRIBUTE -- C_ATTRIBUTE that owns this C_OBJECT. 

Constraints
NameExpression
rm_type_name_validinv: rm_type_name <> Void and not node_id.is_empty 
node_id_validinv: node_id <> Void and not node_id.is_empty 


Parent Package: constraint_model
Class CARDINALITY

Expresses constraints on the cardinality of container objects which are the values of multiply-valued attributes, including uniqueness and ordering, providing the means to state that a container acts like a logical list, set or bag. The cardinality cannot contradict the cardinality of the corresponding attribute within the relevant reference model.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 interval : Interval<Integer>  --  The interval (range) of this cardinality. 
 is_ordered : Boolean  --  True if the members of the container attribute to which this cardinality refers are ordered. 
 is_unique : Boolean  --  True if the members of the container attribute to which this cardinality refers are unique. 

Operations
SignatureConstraintsDocumentation
 is_bag() : Boolean 
post: is_bag=not is_ordered and not is_unique  
True if the semantics of this cardinality represent a set, i.e. unordered, unique membership. 
 is_list() : Boolean 
post: is_list=is_ordered and not is_unique  
True if the semantics of this cardinality represent a list, i.e. ordered, non-unique membership. 
 is_set() : Boolean 
post: is_set=not is_ordered and is_unique  
True if the semantics of this cardinality represent a bag, i.e. unordered, non-unique membership. 

Constraints
NameExpression
validityinv: not interval.lower_unbounded 


Parent Package: constraint_model
Class CONSTRAINT_REF


C_REFERENCE_OBJECT
   |
   +--CONSTRAINT_REF

Reference to a constraint described in the same archetype, but outside the main constraint structure. This is used to refer to constraints expressed in terms of external resources, such as constraints on terminology value sets.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 reference : String  --  Reference to a constraint in the archetype local ontology. 

Constraints
NameExpression
Consistencyinv: not any_allowed 
reference_validinv: reference <> Void  


Parent Package: constraint_model
Class ARCHETYPE_INTERNAL_REF


C_REFERENCE_OBJECT
   |
   +--ARCHETYPE_INTERNAL_REF

A constraint defined by proxy, using a reference to an object constraint defined elsewhere in the same archetype. Note that since this object refers to another node, there are two objects with available occurrences values. The local occurrences value on an ARCHETYPE_INTERNAL_REF should always be used; when setting this from a serialised form, if no occurrences is mentioned, the target occurrences should be used (not the standard default of {1..1}); otherwise the locally specified occurrences should be used as normal. When serialising out, if the occurrences is the same as that of the target, it can be left out.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 target_path : String  --  Reference to an object node using archetype path notation. 

Constraints
NameExpression
consistencyinv: not any_allowed 
target_path_validinv: target_path <>Void and not target_path.is_empty and ultimate_root.has_path(target_path)  


Parent Package: constraint_model
Class ARCHETYPE_SLOT


C_REFERENCE_OBJECT
   |
   +--ARCHETYPE_SLOT

Constraint describing a `slot' where another archetype can occur.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 excludes : List<ASSERTION> 0..1  --  List of constraints defining other archetypes that cannot be included at this point. 
 includes : List<ASSERTION> 0..1  --  List of constraints defining other archetypes that could be included at this point. 

Constraints
NameExpression
includes_validinv: includes <> Void implies not includes.is_empty 
excludes_validinv: excludes <> Void implies not excludes.is_empty 
validityinv: any_allowed xor includes <> Void or excludes <> Void 


Parent Package: constraint_model
Class C_SINGLE_ATTRIBUTE


C_ATTRIBUTE
   |
   +--C_SINGLE_ATTRIBUTE

Concrete model of constraint on a single-valued attribute node. The meaning of the inherited children attribute is that they are alternatives.


Operations
SignatureConstraintsDocumentation
 alternatives() : List<C_OBJECT>  List of alternative constraints for the single child of this attribute within the data. 

Constraints
NameExpression
alternatives_existsinv: alternatives <> Void 


Parent Package: constraint_model
Class C_MULTIPLE_ATTRIBUTE


C_ATTRIBUTE
   |
   +--C_MULTIPLE_ATTRIBUTE

Abstract model of constraint on any kind of attribute node.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 cardinality : CARDINALITY0..1  -- Cardinality of this attribute constraint, if it constrains a container attribute. 

Operations
SignatureConstraintsDocumentation
 members() : List<C_OBJECT>  List of constraints representing members of the container value of this attribute within the data. Semantics of the uniqueness and ordering of items in the container are given by the cardinality . 

Constraints
NameExpression
members_valid inv: members <> Void and members->for_all(co: C_OBJECT | co.occurrences.upper <= 1) 
cardinality_validityinv: cardinality <> Void 


Parent Package: constraint_model
Class C_DOMAIN_TYPE{Abstract}


C_DEFINED_OBJECT
   |
   +--C_DOMAIN_TYPE

Direct Subclassifiers:
       C_DV_STATE, C_DV_ORDINAL, C_DV_QUANTITY, C_CODE_PHRASE

Abstract parent type of domain-specific constrainer types, to be defined in external packages.


Operations
SignatureConstraintsDocumentation
 standard_equivalent() : C_COMPLEX_OBJECT  Standard form of constraint 

Constraints
NameExpression
Assumed_value_validinv: has_assumed_value implies valid_value(assumed_value) 


Parent Package: constraint_model
Class C_COMPLEX_OBJECT


C_DEFINED_OBJECT
   |
   +--C_COMPLEX_OBJECT

Constraint on complex objects, i.e. any object that consists of other object constraints.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 attributes : Set<C_ATTRIBUTE>0..1 List of constraints on attributes of the reference model type represented by this object.  
 invariants : Set<ASSERTION>0..1 0..* Invariant statements about this object. Statements are expressed in first order predicate logic, and usually refer to at least two attributes. 

Constraints
NameExpression
attributes_validinv: any_allowed xor (attributes <> Void and not attributes.is_empty) 


Parent Package: constraint_model
Class C_PRIMITIVE_OBJECT


C_DEFINED_OBJECT
   |
   +--C_PRIMITIVE_OBJECT

Constraint on a primitive type.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 item : C_PRIMITIVE -- Object actually defining the constraint. 

Constraints
NameExpression
item_existsinv: any_allowed xor item <> Void 


Parent Package: constraint_model
Class C_DEFINED_OBJECT{Abstract}


C_OBJECT
   |
   +--C_DEFINED_OBJECT

Direct Subclassifiers:
       C_DOMAIN_TYPE, C_PRIMITIVE_OBJECT, C_COMPLEX_OBJECT

Abstract parent type of C_OBJECT subtypes that are defined by value, i.e. whosedefinitions are actually in the archetype rather than being by reference.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Any 0..1  --  Value to be assumed if none sent in data 

Operations
SignatureConstraintsDocumentation
 any_allowed() : Boolean  True if any value (i.e. instance) of the refer-ence model type would be allowed. Redefined in descendants. 
 default_value() : Any  Generate a default value from this constraint object 
 has_assumed_value() : Boolean  True if there is an assumed value 
 valid_value(a_value : Any) : Boolean 
pre: a_value <> Void  
True if a_value is valid with respect to con-straint expressed in concrete instance of this type. 

Constraints
NameExpression
Assumed_value_validinv: has_assumed_value implies valid_value(assumed_value) 


Parent Package: constraint_model
Class C_REFERENCE_OBJECT{Abstract}


C_OBJECT
   |
   +--C_REFERENCE_OBJECT

Direct Subclassifiers:
       ARCHETYPE_SLOT, ARCHETYPE_INTERNAL_REF, CONSTRAINT_REF

Abstract parent type of C_OBJECT subtypes that are defined by reference.


Parent Package: constraint_model
Package :: primitive

Ultimately any archetype definition will devolve down to leaf node constraints on instances of primitive types. The primitives package defines the semantics of constraint on such types. Most of the types provide at least two alternative ways to represent the constraint; for example the C_DATE type allows the constraint to be expressed in the form of a pattern (defined in the ADL specification) or an Interval. Note that the interval form of dates is probably only useful for historical date checking (e.g. the date of an antique or a particular batch of vaccine), rather than constraints on future date/times.


Inner Elements
NameType
 C_BOOLEANClass
 C_DATEClass
 C_DATE_TIMEClass
 C_DURATIONClass
 C_INTEGERClass
 C_PRIMITIVEClass
 C_REALClass
 C_STRINGClass
 C_TIMEClass
 VALIDITY_KINDEnumeration


Parent Package: primitive
Class C_STRING


C_PRIMITIVE
   |
   +--C_STRING

Constraint on instances of STRING .


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : String 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 list : Set<List<String>0..1 0..*  List of Strings specifying constraint 
 list_open : Boolean 0..1  --  True if the list is being used to specify the constraint but is not considered exhaustive. 
 pattern : String 0..1  --  Regular expression pattern for proposed instances of String to match. 

Constraints
NameExpression
pattern_existsinv: pattern <> Void implies not pattern.is_empty 
consistencyinv: pattern <> Void xor list <> Void 


Parent Package: primitive
Class C_BOOLEAN


C_PRIMITIVE
   |
   +--C_BOOLEAN

Constraint on instances of Boolean . Both attributes cannot be set to False, since this would mean that the Boolean value being constrained cannot be True or False.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Boolean 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 false_valid : Boolean  --  True if the value False is allowed 
 true_valid : Boolean  --  True if the value True is allowed 

Constraints
NameExpression
Default_value_consistencyinv: (default_value.value and true_valid) or (not default_value.value and false_valid) 
binary_consistencyinv: true_valid or false_valid 


Parent Package: primitive
Class C_DURATION


C_PRIMITIVE
   |
   +--C_DURATION

ISO 8601-compatible constraint on instances of Duration. In ISO 8601 terms, constraints might are of the form “PWD” (weeks and/or days), “PDTHMS” (days, hours, minutes, seconds) and so on. In official ISO 8601:2004, the ‘W’ (week) designator cannot be mixed in; allowing it is an openEHR-wide exception.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Duration 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 days_allowed : Boolean 0..1  --  True if days are allowed in the constrained Duration. 
 fractional_seconds_allowed : Boolean 0..1  --  True if fractional seconds are allowed in the constrained Duration. 
 hours_allowed : Boolean 0..1  --  True if hours are allowed in the constrained Duration. 
 minutes_allowed : Boolean 0..1  --  True if minutes are allowed in the constrained Duration. 
 months_allowed : Boolean 0..1  --  True if months are allowed in the constrained Duration. 
 range : Interval<Duration> 0..1  --  Constraint on instances of Duration . 
 seconds_allowed : Boolean 0..1  --  True if seconds are allowed in the constrained Duration. 
 weeks_allowed : Boolean 0..1  --  True if weeks are allowed in the constrained Duration. 
 years_allowed : Boolean 0..1  --  True if years are allowed in the constrained Duration 

Constraints
NameExpression
range_validinv: range <> Void or (years_allowed or months_allowed or weeks_allowed or days_allowed or hours_allowed or minutes_allowed or seconds_allowed or fractional_seconds_allowed) 


Parent Package: primitive
Class C_DATE_TIME


C_PRIMITIVE
   |
   +--C_DATE_TIME

ISO 8601-compatible constraint on instances of Date_Time. There is no validity flag for ‘year’, since it must always be by definition mandatory in order to have a sensible date/time at all. Syntax expressions of instances of this class include “YYYY-MM-DDT??:??:??” (date/time ith optional time) and “YYYY-MMDDTHH: MM:xx” (date/time, seconds not allowed).


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Date_Time 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 day_validity : VALIDITY_KIND 0..1  --  Validity of day in constrained date. 
 hour_validity  : VALIDITY_KIND 0..1  --  Validity of hour in constrained time. 
 millisecond_validity : VALIDITY_KIND 0..1  --  Validity of millisecond in constrained time. 
 minute_validity : VALIDITY_KIND 0..1  --  Validity of minute in constrained time. 
 month_validity : VALIDITY_KIND 0..1  --  Validity of month in constrained date. 
 range : Interval<Date_Time> 0..1  --  Range of Date_times specifying constraint 
 second_validity : VALIDITY_KIND 0..1  --  Validity of second in constrained time. 
 timezone_validity : VALIDITY_KIND 0..1  --  Validity of timezone in constrained date. 

Operations
SignatureConstraintsDocumentation
 validity_is_range() : Boolean  True if validity is in the form of a range; useful for developers to check which kind of constraint has been set. 

Constraints
NameExpression
second_validity_disallowed inv: second_validity = VALIDITY_KIND.disallowed implies millisecond_validity = VALIDITY_KIND.disallowed 
second_validity_optional inv: second_validity = VALIDITY_KIND.optional implies (millisecond_validity = VALIDITY_KIND.optional or millisecond_validity = VALIDITY_KIND.disallowed) 
minute_validity_optional inv: minute_validity = VALIDITY_KIND.optional implies (second_validity = VALIDITY_KIND.optional or second_validity = VALIDITY_KIND.disallowed) 
minute_validity_disallowed inv: minute_validity = VALIDITY_KIND.disallowed implies second_validity = VALIDITY_KIND.disallowed 
hour_validity_disallowed inv: hour_validity = VALIDITY_KIND.disallowed implies minute_validity = VALIDITY_KIND.disallowed 
day_validity_disallowed inv: day_validity = VALIDITY_KIND.disallowed implies hour_validity = VALIDITY_KIND.disallowed 
month_validity_disallowed inv: month_validity = VALIDITY_KIND.disallowed implies day_validity = VALIDITY_KIND.disallowed  
day_validity_optional inv: day_validity = VALIDITY_KIND.optional implies (hour_validity = VALIDITY_KIND.optional or hour_validity =VALIDITY_KIND.disallowed)  
hour_validity_optional inv: hour_validity = VALIDITY_KIND.optional implies (minute_validity = VALIDITY_KIND.optional or minute_validity = VALIDITY_KIND.disallowed) 
validity_is_range inv: validity_is_range = (range <> Void) 
month_validity_optionalinv: month_validity = VALIDITY_KIND.optional implies (day_validity = VALIDITY_KIND.optional or day_validity = VALIDITY_KIND.disallowed)  


Parent Package: primitive
Class C_INTEGER


C_PRIMITIVE
   |
   +--C_INTEGER

Constraint on instances of Integer .


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Integer 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 list : Set<Integer> 0..1  --  Set of Integers specifying constraint 
 range : Interval<Integer> 0..1  --  Range of Integers specifying constraint 

Constraints
NameExpression
consistencyinv: list <> Void xor range <> Void 


Parent Package: primitive
Class C_TIME


C_PRIMITIVE
   |
   +--C_TIME

ISO 8601-compatible constraint on instances of Time. There is no validity flag for ‘hour’, since it must always be by definition mandatory in order to have a sensible time at all. Syntax xpressions of instances of this class include “HH:??:xx” (time with optional minutes and seconds not allowed).


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Time 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 millisecond_validity : VALIDITY_KIND 0..1  --  Validity of millisecond in constrained time. 
 minute_validity : VALIDITY_KIND 0..1  --  Validity of minute in constrained time. 
 range : Interval<Time> 0..1  --  Interval of Times specifying constraint 
 second_validity : VALIDITY_KIND 0..1  --  Validity of second in constrained time. 
 timezone_validity : VALIDITY_KIND 0..1  --  Validity of timezone in constrained date. 

Operations
SignatureConstraintsDocumentation
 validity_is_range() : Boolean  True if validity is in the form of a range; useful for developers to check which kind of constraint has been set. 

Constraints
NameExpression
minute_validity_optionalinv: minute_validity = VALIDITY_KIND.optional implies (second_validity = VALIDITY_KIND.optional or second_validity = VALIDITY_KIND.disallowed) 
second_validity_disallowedinv: second_validity = VALIDITY_KIND.disallowed implies millisecond_validity = VALIDITY_KIND.disallowed 
second_validity_optional:inv: second_validity = VALIDITY_KIND.optional implies (millisecond_validity = VALIDITY_KIND.optional or millisecond_validity = VALIDITY_KIND.disallowed) 
minute_validity_disallowedinv: minute_validity = VALIDITY_KIND.disallowed implies second_validity = VALIDITY_KIND.disallowed 
validity_is_rangeinv: validity_is_range = (range <> Void) 


Parent Package: primitive
Class C_REAL


C_PRIMITIVE
   |
   +--C_REAL

Constraint on instances of Real .


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Real 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 list : Set<Set<Real>0..1 0..*  Set of Reals specifying constraint 
 range : Interval<Real> 0..1  --  Range of Real specifying constraint 

Constraints
NameExpression
consistencyinv: list <> Void xor range <> Void 


Parent Package: primitive
Class C_DATE


C_PRIMITIVE
   |
   +--C_DATE

ISO 8601-compatible constraint on instances of Date in the form either of a set of validity values, or an actual date range. There is no validity flag for ‘year’, since it must always be by definition mandatory in order to have a sensible date at all. Syntax expressions of instances of this class include “YYYY-??-??” (date with optional month and day).


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 assumed_value : Date 0..1  --  The value to assume if this item is not included in data, due to being part of an optional structure. 
 day_validity : VALIDITY_KIND 0..1  --  Validity of day in constrained date. 
 month_validity : VALIDITY_KIND 0..1  --  Validity of month in constrained date. 
 range : Interval<Date> 0..1  --  Interval of Dates specifying constraint 
 timezone_validity : VALIDITY_KIND 0..1  --  Validity of timezone in constrained date. 

Operations
SignatureConstraintsDocumentation
 validity_is_range() : Boolean  True if validity is in the form of a range; useful for developers to check which kind of constraint has been set. 

Constraints
NameExpression
validity_is_rangeinv: validity_is_range = (range <> Void) 
month_validity_optionalinv: month_validity = VALIDITY_KIND.optional implies (day_validity = VALIDITY_KIND.optional or day_validity = VALIDITY_KIND.disallowed) 
month_validity_disallowedinv: month_validity = {VALIDITY_KIND}.disallowed implies day_validity = {VALIDITY_KIND}.disallowed 


Parent Package: primitive
Class C_PRIMITIVE{Abstract}

Direct Subclassifiers:
       C_STRING, C_INTEGER, C_TIME, C_REAL, C_BOOLEAN, C_DATE, C_DURATION, C_DATE_TIME


Operations
SignatureConstraintsDocumentation
 assumed_value() : Any  Value to be assumed if none sent in data 
 default_value() : Any  Generate a default value from this constraint object 
 has_assumed_value() : Boolean  True if there is an assumed value 
 valid_value(a_value : Any) : Boolean 
pre: a_value <> Void  
True if a_value is valid with respect to constraint expressed in concrete instance of this type. 

Constraints
NameExpression
Assumed_value_validinv: has_assumed_value implies valid_value(assumed_value) 


primitive
Enumeration VALIDITY_KIND

General Info
Name  VALIDITY_KIND
Visibility  public
Abstract  false
Leaffalse
Rootfalse
Ownerprimitive

Enumeration Literals
 disallowed
 mandatory
 optional

Constraints
NameExpression
Validityinv: valid_validity(value) 


Parent Package: archetype
Package :: ontology

All linguistic and terminological entities in an archetype are represented in the ontology part of an archetype, whose semantics are given in the Ontology package.


Inner Elements
NameType
 ARCHETYPE_ONTOLOGYClass
 ARCHETYPE_TERMClass


Parent Package: ontology
Class ARCHETYPE_ONTOLOGY

Local ontology of an archetype.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 constraint_codes : List<String>  --  List of all term codes in the ontology. These correspond to the "ac" codes in an ADL archetype, or equivalently, the CONSTRAINT_REF . reference values in the archetype definition. 
 specialisation_depth : Integer  --  Specialisation depth of this archetype. Unspecialised archetypes have depth 0, with each additional level of specialisation adding 1 to the specialisation_depth. 
 term_attribute_names : List<String>  --  List of `attribute' names in ontology terms, typically includes `text', `description', `provenance' etc. 
 term_codes : List<String>  --  List of all term codes in the ontology. Most of these correspond to "at" codes in an ADL archetype, which are the node_ids on C_OBJECT descendants. There may be an extra one, if a different term is used as the overall archetype concept_code from that used as the node_id of the outermost C_OBJECT in the definition part. 
 terminologies_available : Set<String>  --  List of terminologies to which term or constraint bindings exist in this terminology. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 parent_archetype : ARCHETYPE --  

Operations
SignatureConstraintsDocumentation
 constraint_binding(a_terminology : String, a_code : String) : String 
pre: has_terminology(a_terminology_id) and constraint_codes.has(a_code)  
Binding of constraint corresponding to a_code in target external terminology a_terminology_id , as a string, which is usually a formal query expression. 
 constraint_definition(a_lang : String, a_code : String) : ARCHETYPE_TERM 
pre: has_language(a_lang) and constraint_codes.has(a_code)  post: is_set=not is_ordered and is_unique  
Constraint definition for a code, in a specified language. 
 has_language(a_lang : String) : Boolean  True if language `a_lang' is present in archetype ontology. 
 has_terminology(a_terminology : String) : Boolean 
pre: has_terminology(a_terminology_id) pre: has_terminology(a_terminology_id) and term_codes.has(a_code)  
True if terminology `a_terminology' is present in archetype ontology. 
 term_binding(a_terminology : String, a_code : String) : CODE_PHRASE 
pre: has_terminology(a_terminology_id) and term_codes.has(a_code)  
Binding of term corresponding to a_code in target external terminology a_terminology_id as a CODE_PHRASE . 
 term_definition(a_lang : String, a_code : String) : ARCHETYPE_TERM 
pre: has_language(a_lang) and term_codes.has(a_code)  
Term definition for a code, in a specified language. 

Constraints
NameExpression
term_bindings_existsinv: term_bindings <> void 
terminologies_available_existsinv: terminologies_available <> void 
term_attribute_names_validinv: term_attribute_names <> void and term_attribute_names.has('text') and term_attribute_names.has('description') 
constraint_bindings_existsinv: constraint_bindings <> void 
parent_archetype_validinv: parent_archetype <> Void and parent_archetype.description = Current 
constraint_codes_existsinv: constraint_codes <> void 
concept_code_validinv: term_codes.has (concept_code) 
term_codes_existsinv: term_codes <> void 


Parent Package: ontology
Class ARCHETYPE_TERM

Representation of any coded entity (term or constraint) in the archetype ontology.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 code : String  --  Code of this term. 
 items : Hash<String,String>  --  Hash of keys ("text", "description" etc) and corresponding values. 

Operations
SignatureConstraintsDocumentation
 keys() : Set<String>  All keys used in this term. 

Constraints
NameExpression
code_validinv: code <> void and not code.is_empty 
keys_validinv: keys <> Void 


Parent Package: am
Package :: openehr_profile


Inner Elements
NameType
 data_typesPackage


Parent Package: openehr_profile
Package :: data_types

This data type specification constitutes the lowest level of technical specification of openEHR, and describes a set of types suitable for use in clinical and related information structures. In order for such types to exist, a set of primitive types is assumed, namely Integer, Real, Boolean, Character, String, List, Set, and Array. These have standard definitions in the OMG object model used in UML, OCL, and are available in almost all type systems. The exact assumptions are described in the openEHR Support Reference Model. A number of symbolic definitions (similar to constants in programming) are also described in the Support RM. The data types described here are named with the class prefix “DV_”, and inherit from the class DATA_VALUE. They have two distinct uses in reference models. Firstly, they may be used as “data values” in reference model structures wherever the DATA_VALUE class appears, for example, in the EHR Reference Model via the ELEMENT.value attribute. Additionally, specific subtypes of the data types described here can also be used as attribute types in other classes in reference models, such as date/times, coded terms and so on. The difference is that in the former case, only subtypes of DATA_VALUE may be used, whilst in the latter case, other types may be used as well, from the assumed set of basic types.


Inner Elements
NameType
 basicPackage
 quantityPackage
 textPackage


Parent Package: data_types
Package :: basic


Inner Elements
NameType
 C_DV_STATEClass
 NON_TERMINAL_STATEClass
 STATEClass
 STATE_MACHINEClass
 TERMINAL_STATEClass
 TRANSITIONClass


Parent Package: basic
Class TRANSITION

Definition of a state machine transition.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 action : String 0..1  --  Side-effect action to execute during the firing of this transition 
 event : String  --  Event which fires this transition 
 guard : String 0..1  --  Guard condition which must be true for this transition to fire 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 next_state : STATE0..1  -- Target state of transition 

Constraints
NameExpression
Action_validinv: action <> Void implies not action.is_empty  
Guard_validinv: guard <> Void implies not guard.is_empty  
Event_validinv: event <> Void and not event.is_empty  
Next_state_validinv: next_state <> Void 


Parent Package: basic
Class C_DV_STATE


C_DOMAIN_TYPE
   |
   +--C_DV_STATE

Constrainer type for DV_STATE instances. The attribute c_value defines a state/event table which constrains the allowed values of the attribute value in a DV_STATE instance, as well as the order of transitions between values.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 value : STATE_MACHINE --  

Constraints
NameExpression
c_value_existsinv: value <> Void 


Parent Package: basic
Class STATE{Abstract}

Direct Subclassifiers:
       NON_TERMINAL_STATE, TERMINAL_STATE

Abstract definition of one state in a state machine.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 name : String  --  name of this state 

Constraints
NameExpression
Name_validinv: name <> Void and not name.is_empty 
Transitions_validinv: transitions <> Void and not transitions.is_empty 


Parent Package: basic
Class STATE_MACHINE

Definition of a state machine in terms of states, transition events and outputs, and next states.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 states : Set<STATE>1..*   

Constraints
NameExpression
States_validinv: states <> Void and not states.isempty 


Parent Package: basic
Class TERMINAL_STATE


STATE
   |
   +--TERMINAL_STATE


Parent Package: basic
Class NON_TERMINAL_STATE


STATE
   |
   +--NON_TERMINAL_STATE

Definition of a non-terminal state in a state machine, i.e. one that has transitions.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 transitions : Set<TRANSITION>1..*   

Constraints
NameExpression
Transitions_validinv: transitions <> Void and not transitions.is_empty 


Parent Package: data_types
Package :: quantity


Inner Elements
NameType
 C_DV_ORDINALClass
 C_DV_QUANTITYClass
 C_QUANTITY_ITEMClass


Parent Package: quantity
Class C_QUANTITY_ITEM

Constrain instances of DV_QUANTITY.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 magnitude : Interval<Real> 0..1  --  

Constraint on the magnitude of the DV_QUANTITY.

 
 precision : Interval<Integer> 0..1  --  

Constraint on the precision of the DV_QUANTITY.

A value of -1 means that precision is unconstrained.

 
 units : String 0..1  --  

Constraint on the units of the DV_QUANTITY.

 

Operations
SignatureConstraintsDocumentation
 precision_unconstrained() : Boolean 
inv: units <> Void and not units.is_empty  
True if no constraint on precision; True if precision = -1. 

Constraints
NameExpression
units_validinv: units<> Void and not units.is_empty 


Parent Package: quantity
Class C_DV_ORDINAL


C_DOMAIN_TYPE
   |
   +--C_DV_ORDINAL

Class specifying constraints on instances of DV_ORDINAL. Custom constrainer type for instances of DV_ORDINAL.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 list : Set<DV_ORDINAL>0..1 Set of allowed DV_ORDINAL values. 

Constraints
NameExpression
Items_validinv: not list.is_empty 
Ordinals_validinv:items <> Void xor any_allowed  


Parent Package: quantity
Class C_DV_QUANTITY


C_DOMAIN_TYPE
   |
   +--C_DV_QUANTITY

Constrain instances of DV_QUANTITY.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 property : CODE_PHRASE 0..1  --  Optional constraint on units property 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 list : List<C_QUANTITY_ITEM>0..1 0..* ordered  
 list : Set<C_QUANTITY_ITEM>0..1 0..* List of value/units pairs. 

Constraints
NameExpression
List_validinv: list <> Void implies not list.is_empty  
overall_validityinv: (list <> Void or property <> Void) xor any_allowed 
property_validinv: property <> Void implies terminology(Terminology_id_openehr) .has_code_for_group_id (Group_id_property, property)  


Parent Package: data_types
Package :: text


Inner Elements
NameType
 C_CODE_PHRASEClass


Parent Package: text
Class C_CODE_PHRASE


C_DOMAIN_TYPE
   |
   +--C_CODE_PHRASE

Express constraints on instances of CODE_PHRASE. The terminology_id attribute may be specified on its own to indicate any term from a specified terminology; the code_list attribute may be used to limit the codes to a specific list.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 code_list : List<String> 0..1  --  List of allowed codes; may be empty, meaning any code in the terminology may be used. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 terminology_id : TERMINOLOGY_ID0..1  --  

Operations
SignatureConstraintsDocumentation
 any_allowed() : Boolean 
post: Result = terminology_id = Void and code_list = Void  
True if any CODE_PHRASE instance allowed. 

Constraints
NameExpression
Any_allowed_validityinv: any_allowed xor terminology_id <> Void  
List_validityinv: code_list <> Void implies (not code_list.is_empty and terminology_id <> Void) 


Parent Package: am
Package :: template


Package :: assumed_types

This package provides models for common generic and container types not directly supported in UML.


Inner Elements
NameType
 AggregateClass
 ArrayClass
 HashClass
 IntervalClass
 ISO8601_DATEClass
 ISO8601_DATE_TIMEClass
 ISO8601_DURATIONClass
 ISO8601_TIMEClass
 ISO8601_TIMEZONEClass
 ListClass
 SetClass
 StringClass
 TIME_DEFINITIONSClass


Parent Package: assumed_types
Class List{Abstract}


Aggregate
   |
   +--List

Ordered container that may contain duplicates.


Stereotypes
<<Interface>>

Template Parameters
NameTypeDefault Value
  

Operations
SignatureConstraintsDocumentation
 first() : T  Return first element. 
 last() : T  Return last element. 

Constraints
NameExpression
Last_validityinv: not is_empty implies last <> Void 
First_validityinv: not is_empty implies first <> Void 


Parent Package: assumed_types
Class Set{Abstract}


Aggregate
   |
   +--Set

Non-ordered conatiner that does not contain duplicates


Stereotypes
<<Interface>>

Template Parameters
NameTypeDefault Value
  


Parent Package: assumed_types
Class Interval


Any
   |
   +--Interval

Direct Subclassifiers:
       DV_INTERVAL


Stereotypes
<<Interface>>

Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 lower : T  --  Lower bound. 
 lower_included : Boolean  --  lower boundary value included in range if not lower_unbounded 
 lower_unbounded : Boolean  --  lower boundary open (i.e. = -infinity) 
 upper : T  --  Upper bound. 
 upper_included : Boolean  --  upper boundary value included in range if not upper_unbounded 
 upper_unbounded : Boolean  --  upper boundary open (i.e. = +infinity) 

Template Parameters
NameTypeDefault Value
Ordered  

Operations
SignatureConstraintsDocumentation
 has(e : T) : Boolean   

Constraints
NameExpression
Limits_comparableinv: (not upper_unbounded and not lower_unbounded) implies lower.strictly_comparable_to(upper) 
Limits_consistentinv: (not upper_unbounded and not lower_unbounded) implies lower <= upper  
Lower_included_validinv: lower_unbounded implies not lower_included 
Upper_included_validinv: upper_unbounded implies not upper_included 


Parent Package: assumed_types
Class Hash{Abstract}


Aggregate
   |
   +--Hash

Type representing a keyed table of values. T is the value type, and U the type of the keys.


Stereotypes
<<Interface>>

Template Parameters
NameTypeDefault Value
Ordered  
  

Operations
SignatureConstraintsDocumentation
 has_key(a_key : U) : Boolean  Test for membership of a key 
 item(a_key : T) : T  Return item for key ‘a_key’. Equivalent to ISO 11404 fetch operation. 


Parent Package: assumed_types
Class Aggregate{Abstract}


Any
   |
   +--Aggregate

Direct Subclassifiers:
       Set, String, List, Hash, Array

Abstract parent of of the aggregate types List, Set, Array and Hash.


Stereotypes
<<Interface>>

Template Parameters
NameTypeDefault Value
  

Operations
SignatureConstraintsDocumentation
 count() : Integer  Number of items in container 
 has(v : T) : Boolean  Test for membership of a value 
 is_empty() : Boolean  True if container is empty. 


Parent Package: assumed_types
Class Array{Abstract}


Aggregate
   |
   +--Array

Container whose storage is assumed to be contiguous


Stereotypes
<<Interface>>

Template Parameters
NameTypeDefault Value
  


Parent Package: assumed_types
Class ISO8601_DATE


TIME_DEFINITIONS
   |
   +--ISO8601_DATE

Implementing Classifiers:
       DV_DATE

Represents an absolute point in time, as measured on the Gregorian calendar, and specified only to the day.


Operations
SignatureConstraintsDocumentation
 as_string() : String  

ISO8601 string for date, in format YYYYMMDD or YYYY-MM-DD, or a partial invariant. See valid_iso8601_date for validity.

 
 day() : Integer  returns the day of the momth, derived from the string value 
 day_unknown() : Boolean  Indicates whether day in month is unknown. If so, and month is known, the date is of the form “YYYY-MM” or “YYYYMM”. 
 infix('<' : Character, other : ISO8601_DATE) : Boolean  Arithmetic comparison with other date. True if this date is closer to the origin than other. 
 is_extended() : Boolean  True if this date uses ‘-’ separators. 
 is_partial() : Boolean  True if this date is partial, i.e. if day or more is missing. 
 month() : Integer 
pre: not month_unknown  
returns the month in year derived from the string value 
 month_unknown() : Boolean  Indicates whether month in year is unknown. If so, the date is of the form “YYYY”. 
 valid_iso8601_date(s : String) : Boolean  

String is a valid ISO 8601 date, i.e. takes the complete form:

YYYYMMDD

or the extended form:

YYYY-MM-DD

or one of the partial forms:

YYYYMM

YYYY

or the equivalent extended form:

YYYY-MM

Where:

YYYY is the string form of any positive number in the range “0000” - “9999”

(zero-filled to four digits)

MM is “01” - “12” (zero-filled to two

digits)

DD is “01” - “31” (zero-filled to two

digits)

The combinations of YYYY, MM, DD numbers ust be correct with respect to the Gregorian calendar.

 
 year() : Integer  returns the year derived from the string value 

Constraints
NameExpression
Hour_validinv: valid_hour(hour, minute, second) 
Second_validinv: not second_unknown implies valid_second(second) 
Partial_validityinv:minute_unknown implies second_unknown 
Year_validinv: valid_year(year) 


Parent Package: assumed_types
Class ISO8601_TIME


TIME_DEFINITIONS
   |
   +--ISO8601_TIME

Implementing Classifiers:
       DV_TIME

Represents an absolute point in time from an origin usually interpreted as meaning the start of the current day, specified to the second.


Operations
SignatureConstraintsDocumentation
 as_string() : String  

ISO8601 string for time, i.e. in form:

hhmmss[,sss][Z|±hhmm] or the extended form:

hh:mm:ss[,sss][Z|±hhmm], or a partial invariant.

See valid_iso8601_time for validity.

 
 fractional_second() : Double 
pre: not second_unknown  
Fractional seconds (just the factional part). 
 has_fractional_second() : Boolean  True if the fractional_second part is signficant (i.e. even if = 0.0). 
 hour() : Integer  Hour in day, in 24-hour time. 
 infix('<' : Character, other : ISO8601_TIME) : Boolean  Arithmetic comparison with other time. True if this date is closer to previous midnight than other. 
 is_decimal_sign_comma() : Boolean  True if this time has a decimal part indicated by ‘,’ (comma) rather than ‘.’ (period). 
 is_extended() : Boolean  True if this time uses ‘:’ separators. 
 is_partial() : Boolean  True if this date is partial, i.e. if seconds or more is missing. 
 minute() : Integer 
pre: not minute_unknown  
Minute in hour.  
 minute_unknown() : Boolean  Indicates whether minute is unknown. If so, the time is of the form “hh”. 
 second() : Integer 
pre: not second_unknown  
Second in minute. 
 second_unknown() : Boolean  Indicates whether second is unknown. If so and month is known, the time is of the form “hh:mm” or “hhmm”. 
 timezone() : ISO8601_TIMEZONE  Timezone; may be Void. 
 valid_iso8601_time(s : String) : Boolean  

String is a valid ISO 8601 date, i.e. takes the form:

hhmmss[,sss][Z | ±hhmm]

or the extended form:

hh:mm:ss[,sss][Z | ±hhmm]

or one of the partial forms:

hhmm or hh

or the extended form:

hh:mm

with an additional optional timezone indicator of:

Z or ±hhmm

Where:

hh is “00” - “24” (0-filled to two digits)

mm is “00” - “59” (0-filled to two digits)

ss is “00” - “60” (0-filled to two digits)

sss is any numeric string, representing an

optional fractional second

Z is a literal meaning UTC (modern

replacement for GMT), i.e. timezone +0000

±hhmm, i.e. +hhmm or -hhmm, indicating

the timezone.

The only combination allowed when hh=24 is

“24:00:00”, meaning “end of the calendar day”

according to the standard.

 

Constraints
NameExpression
Hour_validinv: valid_hour(hour, minute, second) 
Minute_validinv: not minute_unknown implies valid_minute(minute) 
Second_validinv: not second_unknown implies valid_second(second) 
Partial_validityinv:minute_unknown implies second_unknown 
Fractional_second_validinv: has_fractional_second implies (not second_unknown and valid_fractional_second(fractional_second)) 


Parent Package: assumed_types
Class ISO8601_DATE_TIME


TIME_DEFINITIONS
   |
   +--ISO8601_DATE_TIME

Implementing Classifiers:
       DV_DATE_TIME


Operations
SignatureConstraintsDocumentation
 as_string() : String 
post: valid_iso8601_date_time(Result)  

ISO8601 string for date/time, in format

YYYYMMDDThhmmss[,sss][Z | ±hhmm]

or in extended format

YYYY-MM-DDThh:mm:ss[,sss][Z |±hhmm]

or a partial variant; see valid_iso8601_date_time() below.

 
 day() : Integer  day in month 
 day_unknown() : Boolean  Indicates whether day in month is unknown. 
 fractional_second() : Double  fractional seconds 
 has_fractional_second() : Boolean  True if the fractional_second part is signficant (i.e. even if = 0.0). 
 hour() : Integer  hour in day 
 hour_unknown() : Boolean  Indicates whether hour in day is known. 
 infix('<' : Character, other : ISO8601_DATE_TIME) : Boolean  Arithmetic comparison with other date/time. True if this date/time is closer to origin than other. 
 is_decimal_sign_comma() : Boolean  True if this time has a decimal part indicated by ‘,’ (comma) rather than ‘.’ (period). 
 is_extended() : Boolean  True if this date/time uses ‘-’, ‘:’ separators. 
 is_partial() : Boolean  True if this date is partial, i.e. if seconds or more is missing. 
 minute() : Integer  minute in hour 
 minute_unknown() : Boolean  Indicates whether minute in hour is known. 
 month() : Integer  month in year 
 month_unknown() : Boolean  Indicates whether month in year is unknown. 
 second() : Integer  second in minute 
 second_unknown() : Boolean  Indicates whether minute in hour is known. 
 timezone() : ISO8601_TIMEZONE  Timezone; may be Void. 
 valid_fractional_second(fs : Double) : Boolean 
post: Result = (fs>= 0.0 and fs >1.0)  
 
 valid_iso8601_date_time(s : String) : Boolean  

String is a valid ISO 8601 date-time, i.e.

takes the form:

YYYYMMDDThhmmss[,sss][Z|±hhmm]

or the extended form:

YYYY-MM-DDThh:mm:ss[,sss][Z|±hhmm]

or one of the partial forms:

YYYYMMDDThhmm

YYYYMMDDThh

or the equivalent extended forms:

YYYY-MM-DDThh:mm

YYYY-MM-DDThh

(meanings as in DV_DATE, DV_TIME) and

the values in each field are valid.

 
 year() : Integer  year 

Constraints
NameExpression
Partial_validity_minuteinv: minute_unknown implies second_unknown 
Month_validinv: valid_month(month) 
Partial_validity_hourinv: not hour_unknown 
Partial_validity_monthinv: not month_unknown 
Second_validinv: not second_unknown implies valid_second(second) 
Day_validinv: valid_day(year, month, day) 
Year_validinv: valid_year(year) 
Partial_validity_dayinv: not day_unknown 
Fractional_second_validinv: has_fractional_second implies (not second_unknown and valid_fractional_second(fractional_second)) 
Hour_validinv: valid_hour(hour, minute, second) 
Minute_validinv: not minute_unknown implies valid_minute(minute) 
Fractional_second_valid:inv: has_fractional_second implies (not second_unknown and valid_fractional_second(fractional_second)) 
Partial_validity_yearinv: not month_unknown 


Parent Package: assumed_types
Class ISO8601_DURATION


TIME_DEFINITIONS
   |
   +--ISO8601_DURATION

Implementing Classifiers:
       DV_DURATION


Operations
SignatureConstraintsDocumentation
 as_string() : String  

ISO8601 string for duration, in format

P[nnY][nnM][nnW][nnD][T[nnH][nnM][nnS]]

 
 days() : Integer  number of 24 hour days 
 fractional_second() : Double  fractional seconds 
 hours() : Integer  number of 60 minute hours 
 is_decimal_sign_comma() : Boolean  True if this time has a decimal part indicated by ‘,’ (comma) rather than ‘.’ (period). 
 minutes() : Integer  number of 60 second minutes 
 months() : Integer  number of months of nominal 30 day length 
 seconds() : Integer  number of seconds 
 valid_iso8601_duration(s : String) : Boolean  

String is a valid ISO 8601 duration, i.e. takes the form:

P[nnY][nnM][nnW][nnD][T[nnH][nnM][nnS]

Where each nn represents a number of years, months, etc. nnW represents a number of 7-day weeks.

Note: allowing the W designator in the same

expression as other designators is an exception

to the published standard, but necessary

in clinical information (typically for representing

pregnancy duration).

 
 weeks() : Integer  number of 7 day weeks 
 years() : Integer  number of years of nominal 365-day length 

Constraints
NameExpression
months_validinv: months >= 0 
years_validinv: years >= 0 
hours_validinv: hours >= 0 
days_vlidinv: days >= 0 
minutes_validinv: minutes >= 0 
fractional_second_validinv: fractional_seconds >= 0.0 and fractional_seconds < 1.0 
weeks_validinv: weeks >= 0 
seconds_validinv: seconds >= 0 


Parent Package: assumed_types
Class TIME_DEFINITIONS


Any
   |
   +--TIME_DEFINITIONS

Direct Subclassifiers:
       ISO8601_DATE, ISO8601_DURATION, ISO8601_DATE_TIME, ISO8601_TIMEZONE, ISO8601_TIME

Implementing Classifiers:
       DV_DURATION

Definitions for date/time classes. Note that the timezone limits are set by where the international dateline is. Thus, time in New Zealand is quoted using +12:00, not -12:00.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 Days_in_leap_year : Integer  -- 366  
 Days_in_week : Integer  --  
 Days_in_year : Integer  -- 365  
 Hours_in_day : Integer  -- 24  
 Max_days_in_month : Integer  -- 31  
 Max_days_in_year : Integer  -- 366  
 Max_timezone : DV_DURATION  --   
 Min_timezone : DV_DURATION  --   
 Minutes_in_hour : Integer  -- 60  
 Months_in_year : Integer  -- 12  
 Nominal_days_in_month : Real  -- 30.42  
 Nominal_days_in_year : Real  -- 365.24  
 Seconds_in_minute : Integer  -- 60  

Operations
SignatureConstraintsDocumentation
 valid_day(y,m,d : Integer) : Boolean 
post: Result = (d>=1 and d<= Days_in_month(m,y))  
 
 valid_hour(h,m,s : Integer) : Boolean 
post: Result=(h>=0 and h<Hours_in_day) or (h=Hours_in_day and m=0 and s=0)  
 
 valid_minute(m : Integer) : Boolean 
post: Result = (m>=0 and m<Minutes_in_hour)  
 
 valid_month(m : Integer) : Boolean   
 valid_second(s : Integer) : Boolean   
 valid_year(y : Integer) : Boolean 
post: Result=(y>=0)  
True if v>=0 


Parent Package: assumed_types
Class ISO8601_TIMEZONE


TIME_DEFINITIONS
   |
   +--ISO8601_TIMEZONE


Operations
SignatureConstraintsDocumentation
 as_string() : String  

ISO8601 timezone string, in format

Z|±hhmm

 
 hour() : Integer  Hour part of timezone - in the range 00 - 12 
 is_gmt() : Boolean  True if timezone is GMT, i.e. +0000 
 minute() : Integer  Minute part of timezone. Generally 00 or 30. 
 sign() : Integer  Direction of timezone expresssed as +1 or -1. 


Parent Package: assumed_types
Class String


Aggregate
   |
   +--String


Stereotypes
<<Interface>>

Operations
SignatureConstraintsDocumentation
 as_integer() : Integer 
pre: is_integer  
Return the integer corresponding to the integer value represented in this string. 
 infix('+' : Character, other : String) : String  Concatenation operator - causes ‘other’ to be appended to this string 
 is_empty() : Boolean  True if string is empty, i.e. equal to “”. 
 is_integer() : Boolean  True if string can be parsed as an integer. 


Package :: rm


Inner Elements
NameType
 commonPackage
 compositionPackage
 data_structuresPackage
 data_typesPackage
 demographicPackage
 ehrPackage
 integrationPackage
 securityPackage
 supportPackage


Parent Package: rm
Package :: common


Inner Elements
NameType
 archetypedPackage
 change_controlPackage
 directoryPackage
 genericPackage
 resourcePackage


Parent Package: common
Package :: archetyped


Inner Elements
NameType
 ARCHETYPEDClass
 FEEDER_AUDITClass
 FEEDER_AUDIT_DETAILSClass
 LINKClass
 LOCATABLEClass
 PATHABLEClass


Parent Package: archetyped
Class LOCATABLE{Abstract}


PATHABLE
   |
   +--LOCATABLE

Direct Subclassifiers:
       DATA_STRUCTURE, EVENT, COMPOSITION, FOLDER, CONTACT, ACTIVITY, EHR_STATUS, CAPABILITY, EHR_ACCESS, PARTY_RELATIONSHIP, PARTY_IDENTITY, PARTY, ADDRESS, CONTENT_ITEM

Root class of all information model classes that can be archetyped.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 archetype_node_id : String  --  Design-time archetype id of this node taken from its generating archetype; used to build archetype paths. Always in the form of an “at” code, e.g. “at0005”. This value enables a "standardised" name for this node to be generated, by referring to the generating archetype local ontology. At an archetype root point, the value of this attribute is always the stringified form of the archetype_id found in the archetype_details object. 
 name : DV_TEXT  --  Runtime name of this fragment, used to build runtime paths. This is the term provided via a clinical application or batch process to name this EHR construct: its retention in the EHR faithfully preserves the original label by which this entry was known to end users. 
 uid : UID_BASED_ID 0..1  --  Optional globally unique object identifier for root points of archetyped structures. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 links : Set<LINK>0..1 Links to other archetyped structures (data whose root object inherits from ARCHETYPED, such as ENTRY, SECTION and so on). Links may be to structures in other compositions. 
 archetype_details : ARCHETYPED0..1  -- Details of archetyping used on this node. 
 feeder_audit : Set<FEEDER_AUDIT>0..1 0..* Audit trail from non-openEHR system of original commit of information forming the content of this node, or from a conversion gateway which has synthesised this node. 

Operations
SignatureConstraintsDocumentation
 concept() : DV_TEXT 
pre: is_archetype_root  
Clinical concept of the archetype as a whole (= derived from the ‘archetype_node_id’ of the root node) 
 is_archetype_root() : Boolean  True if this node is the root of an archetyped structure. 

Constraints
NameExpression
Name_validinv: name <> Void 
Archetype_node_id_validinv: archetype_node_id <> Void and not archetype_node_id.is_empty 
Links_validinv: links <> Void implies not links.empty 
Archetyped_validinv: is_archetype_root xor archetype_details = Void 


Parent Package: archetyped
Class LINK

The LINK type defines a logical relationship between two items, such as two ENTRYs or an ENTRY and a COMPOSITION. Links can be used across compositions, and across EHRs. Links can potentially be used between interior (i.e. non-archetype root) nodes, although this probably should be prevented in archetypes. Multiple LINKs can be attached to the root object of any archetyped structure to give the effect of a 1->N link


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 meaning : DV_TEXT  --  Used to describe the relationship, usually in clinical terms, such as “in response to” (the relationship between test results and an order), “follow-up to” and so on. Such relationships can represent any clinically meaningful connection between pieces of information. Values for meaning include those described in Annex C, ENV 13606 pt 2 [11] under the categories of “generic”, “documenting and reporting”, “organisational”, “clinical”, “circumstancial”, and “view management”. 
 target : DV_EHR_URI  --  The logical “to” object in the link relation, as per the linguistic sense of the meaning attribute. 
 type : DV_TEXT  --  The type attribute is used to indicate a clinical or domain-level meaning for the kind of link, for example “problem” or “issue”. If type values are designed appropriately, they can be used by the requestor of EHR extracts to categorise links which must be followed and which can be broken when the extract is created. 

Constraints
NameExpression
Meaning_validinv: meaning <> Void 
Type_validinv: type <> Void 
Target_validinv: target <> Void 


Parent Package: archetyped
Class FEEDER_AUDIT


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 feeder_system_item_ids : List<DV_IDENTIFIER> 0..1  --  Identifiers used for the item in the feeder system, where the feeder system is distinct from the originating system. 
 original_content : DV_ENCAPSULATED 0..1  --  Optional inline inclusion of or reference to original content corresponding to the openEHR content at this node. Typically a URI reference to a document or message in a persistent store associated with the EHR. 
 originating_system_item_ids : List<DV_IDENTIFIER> 0..1  --  Identifiers used for the item in the originating system, e.g. filler and placer ids. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 originating_system_audit : FEEDER_AUDIT_DETAILS -- Any audit information for the information item from the originating system. 
 feeder_system_audit : FEEDER_AUDIT_DETAILS0..1  -- Any audit information for the information item from the feeder system, if different from the originating system. 

Constraints
NameExpression
Originating_system_audit_validinv: originating_system_audit <> Void 


Parent Package: archetyped
Class ARCHETYPED

Archetypes act as the configuration basis for the particular structures of instances defined by the reference model. To enable archetypes to be used to create valid data, key classes in the reference model act as “root” points for archetyping; accordingly, these classes have the archetype_details attribute set. An instance of the class ARCHETYPED contains the relevant archetype identification information, allowing generating archetypes to be matched up with data instances


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 archetype_id : ARCHETYPE_ID  --  Globally unique archetype identifier. 
 rm_version : String  --  Version of the openEHR reference model used to create this object. Expressed in terms of the release version string, e.g. “1.0”, “1.2.4”. 
 template_id : TEMPLATE_ID 0..1  --  Globally unique template identifier, if a template was active at this point in the structure. Normally, a template would only be used at the top of a top-level structure, but the possibility exists for templates at lower levels. 

Constraints
NameExpression
rm_version_validinv: rm_version <> Void and not rm_version.is_empty 
archetype_id_validinv: archetype_id <> Void 


Parent Package: archetyped
Class FEEDER_AUDIT_DETAILS

Audit details for any system in a feeder system chain. Audit details here means the general notion of who/where/when the information item to which the audit is attached was created. None of the attributes is defined as mandatory, however, in different scenarios, various combinations of attributes will usually be mandatory. This can be controlled by specifying feeder audit details in legacy archetypes.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 location : PARTY_IDENTIFIED 0..1  --  Identifier of the particular site/facility within an organisation which handled the item. For computability, this identifier needs to be e.g. a PKI identifier which can be included in the identifier list of the PARTY_IDENTIFIED object. 
 provider : PARTY_IDENTIFIED 0..1  --  Optional provider(s) who created, committed, forwarded or otherwise handled the item. 
 subject : PARTY_PROXY 0..1  --  Identifiers for subject of the received information item. 
 system_id : String  --  Identifier of the system which handled the information item. 
 time : DV_DATE_TIME 0..1  --  Time of handling the item. For an originating system, this will be time of creation, for an intermediate feeder system, this will be a time of accession or other time of handling, where available. 
 version_id : String 0..1  --  Any identifier used in the system such as “interim”, “final”, or numeric versions if available. 

Constraints
NameExpression
System_id_validinv: system_id <> Void and not system_id.is_empty 


Parent Package: archetyped
Class PATHABLE{Abstract}

Direct Subclassifiers:
       EVENT_CONTEXT, ISM_TRANSITION, LOCATABLE, INSTRUCTION_DETAILS

Abstract parent of all classes whose instances are reachable by paths, and which know how to locate child object by paths. The parent feature may be implemented as a function or attribute.


Operations
SignatureConstraintsDocumentation
 item_at_path(a_path : String) : Any 
post: Result <> Void pre: path <>Void and valid_path(a_path)  
The item at a path (relative to this item); only valid for unique paths, i.e. paths that resolve to a single item. 
 items_at_path(a_path : String) : List<Any> 
pre: path <>Void and not path_unique(a_path) post: Result <> Void  
List of items corresponding to a non-unique path path. 
 parent() : PATHABLE  Parent of this node in compositional hierarchy. 
 path_exists(a_path : String) : Boolean  True if the path exists in the data with respect to the current item. 
 path_of_item(a_loc : PATHABLE) : String 
pre: an_item <> Void  
The path to an item relative to the root of this archetyped structure. 
 path_unique(a_path : String) : Boolean 
pre: a_path <> Void and path_exists(a_path)  
True if the path corresponds to a single item in the data. 


Parent Package: common
Package :: change_control

In various openEHR reference models, the semantics of formal change control are required. There are two architectural aspects of managing changes to data. The first is the concept of a complex information object, being versioned in time, meaning that its creation and all subsequent modifications cause new “versions” to be created, rather than literally overwriting the existing data. Each version includes an audit trail, typically containing the dentity of a user, the date/time of the change, and a reason for the change. The second aspect recognises that repositories are made up of complex information objects, and that changes are not in fact just made to individual objects, but to the respository itself. Any change by a user may change more than one versioned object in the repository, and the set of such changes - a “change-set” - constitutes the logical unit of change to the repository, taking it from one valid state to the next.


Inner Elements
NameType
 CONTRIBUTIONClass
 IMPORTED_VERSIONClass
 MERGED_VERSIONClass
 ORIGINAL_VERSIONClass
 VERSIONClass
 VERSIONED_OBJECTClass


Parent Package: change_control
Class VERSIONED_OBJECT

Version control abstraction, defining semantics for versioning one complex object.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 owner_id : OBJECT_REF  --  Reference to object to which this versioned repository belongs, e.g. the id of the containing EHR. 
 time_created : DV_DATE_TIME  --  Time of initial creation of this versioned object. 
 uid : HIER_OBJECT_ID  --  Unique identifier of this version repository. 

Template Parameters
NameTypeDefault Value
  

Operations
SignatureConstraintsDocumentation
 all_version_ids() : List<OBJECT_VERSION_ID>  Return a list of ids of all versions in this object. 
 all_versions(T) : List<VERSION>  Return a list of all versions in this object. 
 commit_attestation() :  
pre: an_attestation <> Void and has_version_id(a_ver_id)  
Add a new attestation to a specified original version. Attestations can only be added to Original versions. Parameters: (an_attestation: ATTESTATION; a_ver_id: OBJECT_VERSION_ID; signing_key: String) require Attestation_valid: an_attestation /= Void Version_id_valid: has_version_id(a_ver_id) and is_original_version(a_ver_id) 
 commit _imported_version() :   Add a new imported version. Details of version id etc come from the ORIGINAL_VERSION being committed. Parameters: (a_contribution_id: OBJECT_REF; an_audit: AUDIT_DETAILS; a_version: ORIGINAL_VERSION) require Contribution_valid: a_contribution /= Void audit_valid: an_audit /= Void Version_valid: a_version /= Void 
 commit _original_merged_version() :   Add a new original merged version. This commit function adds a parameter containing the ids of other versions merged into the current one. Parameters: (a_contribution_id: OBJECT_REF; a_new_version_uid, a_preceding_version_uid: OBJECT_VERSION_ID; an_audit: AUDIT_DETAILS; a_lifecycle_state: DV_CODED_TEXT; a_data: T; an_other_input_uids: Set; signing_key: String) require Contribution_valid: a_contribution /= Void New_version_valid: a_new_version_uid /= Void Preceding_version_id_valid: all_version_ids.has(a_preceding_version_uid) or else version_count = 0 audit_valid: an_audit /= Void data_valid: a_version_data /= Void lifecycle_state_valid: a_lifecycle_state /= Void Merge_input_ids_valid: an_other_input_uids /= Void 
 commit_original_version() :   Add a new original version. Parameters: (a_contribution: OBJECT_REF; a_new_version_uid, a_preceding_version_uid: OBJECT_VERSION_ID; an_audit: AUDIT_DETAILS; a_lifecycle_state: DV_CODED_TEXT; a_data: T; signing_key: String) require Contribution_valid: a_contribution /= Void New_version_valid: a_new_version_uid /= Void Preceding_version_uid_valid: all_version_ids.has(a_preceding_version_uid) or else version_count = 0 audit_valid: an_audit /= Void data_valid: a_version_data /= Void lifecycle_state_valid: a_lifecycle_state /= Void  
 has_version_at_time(a_time : DV_DATE_TIME) : Boolean 
pre: a_time <> Void  
True if a version for time ‘a_time’ exists. 
 has_version_id(a_ver_id : OBJECT_VERSION_ID) : Boolean 
pre: a_ver_id <> Void   
True if a version with a_ver_id exists. 
 is_original_version(a_ver_id : OBJECT_VERSION_ID) : Boolean 
pre: a_ver_id <> Void and has_version_id(a_ver_id)  
True if version with an id is an ORIGINAL_VERSION. 
 latest_trunk_version() : VERSION  Return the most recently added trunk version. 
 latest_version() : VERSION  Return the most recently added version (i.e. on trunk or any branch). 
 lifecycle_state() : DV_CODED_TEXT 
post: Result = latest_trunk_version.lifecycle_state   
Return the lifecycle state from the latest trunk version. Useful for determining if the version container is logically deleted. 
 revision_history() : REVISION_HISTORY  History of all audits and attestations in this versioned repository. 
 version_at_time(a_time : DV_DATE_TIME) : VERSION 
pre: has_version_at_time(a_time)  
Return the version for time ‘a_time’. 
 version_count() : Integer  Return the total number of versions in this object 
 version_with_id(a_ver_id : OBJECT_VERSION_ID) : OBJECT_VERSION_ID 
pre: has_version_id(a_ver_id)  
Return the version with id ‘a_ver_id’. 

Constraints
NameExpression
owner_id_validinv: owner_id <> Void 
all_versions_validinv: all_versions <> Void and all_versions.count = version_count 
version_count_validinv: version_count >= 1 
uid_validinv: uid <> Void 
latest_version_validinv: latest_version <> Void 
all_version_ids_validinv: all_version_ids <>Void and all_version_ids.count = version_count 
revision_history_validinv: revision_history <> Void 
time_created_validinv: time_created <> Void 


Parent Package: change_control
Class CONTRIBUTION

Documents a contribution of one or more versions added to a change-controlled repository.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 uid : HIER_OBJECT_ID  --  Unique identifier for this contribution. 
 versions : List<OBJECT_REF>  --  Set of references to versions causing changes to this EHR. Each contribution contains a list of versions, which may include paths pointing to any number of VERSIONABLE items, i.e. items of type COMPOSITION and FOLDER. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 audit : AUDIT_DETAILS -- Audit trail corresponding to the committal of this Contribution. 

Constraints
NameExpression
Versions_validinv: versions <> Void and not versions.is_empty 
Description_validinv: audit.description <> Void 
audit_validmed2inv: audit <> Void 
uid_validinv: uid <> Void 


Parent Package: change_control
Class VERSION{Abstract}

Direct Subclassifiers:
       ORIGINAL_VERSION, IMPORTED_VERSION, MERGED_VERSION

One version within a Version container, containing data, create and commit audit trails, and optional attestations.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 contribution : OBJECT_REF  --  Contribution in which this version was added. 
 signature : String 0..1  --  OpenPGP digital signature or digest of content committed in this Version. 

Template Parameters
NameTypeDefault Value
  

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 commit_audit : AUDIT_DETAILS -- Audit trail corresponding to the committal of this version to the VERSION_REPOSITORY where it is currently located. 
 attestations : Set<ATTESTATION>0..1 0..* Set of attestations relating to this version. 
 data : T0..1  -- The data being versioned. 

Operations
SignatureConstraintsDocumentation
 canonical_form() : String   
 data() : T   
 is_branch() : Boolean   
 lifecycle_state() : DV_CODED_TEXT   
 owner_id() : HIER_OBJECT_ID   
 preceding_version_uid() : OBJECT_VERSION_ID   
 uid() : OBJECT_VERSION_ID   

Constraints
NameExpression
Contribution_validinv: contribution <> Void and contribution.type.is_equal('CONTRIBUTION') 
Data_validinv: data <> Void 
Uid_validinv: uid <> Void 
Owner_id_validinv: owner_id <> Void and owner_id.value.is_equal(uid.object_id.value) 
Lifecycle_state_validinv: lifecycle_state <> Void and terminology( Term_id_openehr). codes_for_group_name(Group_id_version_lifecycle_state, 'en').has(lifecycle_state.defining_code) 
Commit_audit_validinv: commit_audit <> Void 
Create_audit_validinv: create_audit <> Void and create_audit = commit_audit 
Preceding_version_uid_validityinv: uid.version_tree_id.is_first xor preceding_version_uid <> Void 


Parent Package: change_control
Class MERGED_VERSION


VERSION
   |
   +--MERGED_VERSION

Merged Versions, recording the list of input versions to the merge in addition to standard Version attributes.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 input_version_ids : Set<OBJECT_VERSION_ID> 0..1  --  Identifiers of the Versions used as input into this merged version. There is no guarantee that the identifiers of all content Versions are included here. 

Template Parameters
NameTypeDefault Value
  

Constraints
NameExpression
Input_version_ids_validinv: input_version_ids <> Void and not input_version_ids.is_empty 


Parent Package: change_control
Class IMPORTED_VERSION


VERSION
   |
   +--IMPORTED_VERSION

Versionable objects that have been copied from another location and imported into a local version container.


Template Parameters
NameTypeDefault Value
  

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 item : ORIGINAL_VERSION --  

Operations
SignatureConstraintsDocumentation
 data() : T   
 lifecycle_state() : DV_CODED_TEXT   
 preceding_version_uid() : OBJECT_VERSION_ID   
 uid() : OBJECT_VERSION_ID   

Constraints
NameExpression
Original_create_audit_validinv: original_create_audit <> Void 
Create_audit_validinv: create_audit <> Void and create_audit =original_create_audit 


Parent Package: change_control
Class ORIGINAL_VERSION


VERSION
   |
   +--ORIGINAL_VERSION


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 lifecycle_state : DV_CODED_TEXT  --  Lifecycle state of the content item in this version. 
 preceding_version_uid : OBJECT_VERSION_ID  --  Unique identifier of the version of which this version is a modification; Void if this is the first version. 
 uid : OBJECT_VERSION_ID  --  Unique identifier of this version, containing owner_id, version_tree_id and creating_system_id. 

Template Parameters
NameTypeDefault Value
 T  

Operations
SignatureConstraintsDocumentation
 is_merged() : Boolean   


Parent Package: common
Package :: directory

The directory package provides a simple abstraction of a versioned folder structure. The VERSIONED_FOLDER class is the binding of VERSIONED_OBJECT to FOLDER, i.e. it is a VERSIONED_OBJECT. This means that each of its versions is a FOLDER structure. It provides a means of versioning FOLDER structures over time, which is useful in the EHR, Demographics service or anywhere else where Folders are used to group things.


Inner Elements
NameType
 FOLDERClass
 VERSIONED_FOLDERClass


Parent Package: directory
Class VERSIONED_FOLDER


Parent Package: directory
Class FOLDER


LOCATABLE
   |
   +--FOLDER

The concept of a named folder.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 items : List<OBJECT_REF> 0..1  --  The list of references to other (usually) versioned objects logically in this folder. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 

Constraints
NameExpression
Folders_validinv: folders <> Void implies not folders.empty 


Parent Package: common
Package :: generic


Inner Elements
NameType
 ATTESTATIONClass
 AUDIT_DETAILSClass
 PARTICIPATIONClass
 PARTY_IDENTIFIEDClass
 PARTY_PROXYClass
 PARTY_RELATEDClass
 PARTY_SELFClass
 REVISION_HISTORYClass
 REVISION_HISTORY_ITEMClass


Parent Package: generic
Class PARTICIPATION

Model of a participation of a Party (any Actor or Role) in an activity.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 function : DV_TEXT  --  The function of the Party in this participation (note that a given party might participate in more than one way in a particular activity). This attribute should be coded, but cannot be limited to the HL7v3:ParticipationFunction vocabulary, since it is too limited and hospital-oriented. 
 mode : DV_CODED_TEXT  --  The mode of the performer / activity interaction, e.g. present, by telephone, by email etc. 
 time : DV_INTERVAL<DV_DATE_TIME> 0..1  --  The time interval during which the participation took place, if it is used in an observational context (i.e. recording facts about the past); or the intended time interval of the participation when used in future contexts, such as EHR Instructions. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 performer : PARTY_REF --  
 performer : PARTY_PROXY -- The id and possibly demographic system link of the party participating in the activity. 

Constraints
NameExpression
Performer_validinv: performer <> Void 
Mode_validinv: mode <> Void and terminology(Terminology_id_openehr). has_code_for_group_id(Group_id_participation_mode, mode.defining_code) 
Function_validinv: function <> Void and function.generating_type.is_equal('DV_CODED_TEXT') implies terminology(Terminology_id_openehr). has_code_for_group_id(Group_id_participation_function, function. defining_code) 


Parent Package: generic
Class REVISION_HISTORY

Defines the notion of a revision history of audit items, each associated with the version for which that audit was committed.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 items : List<REVISION_HISTORY_ITEM>0..1 * orderedThe items in this history. 

Operations
SignatureConstraintsDocumentation
 most_recent_version() : String 
post: Result.is_equal(items.last.version_id.value)  
The version id of the most recent item, as a String. 
 most_recent_version_time_committed() : String 
post: Result.is_equal(items.last.audits.first.time_committed.value)  
The commit date/time of the most recent item, as a String. 


Parent Package: generic
Class REVISION_HISTORY_ITEM

An entry in a revision history, corresponding to a version from a versioned container Consists of AUDIT_DETAILS instances with revision identifier of the revision to which the AUDIT_DETAILS intance belongs.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 version_id : OBJECT_VERSION_ID  --  Version identifier for this revision. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 audits : Set<AUDIT_DETAILS>1..* The audits for this revision; there will always be at least one commit audit (which may itself be an ATTESTATION), there may also be further attestations. 

Constraints
NameExpression
Version_id_validinv: version_id <> Void 
Audit_validinv: audit <> Void and not audits.is_empty 


Parent Package: generic
Class PARTY_PROXY{Abstract}

Direct Subclassifiers:
       PARTY_IDENTIFIED, PARTY_SELF

Abstract concept of a proxy description of a party, including an optional link to data for this party in a demographic or other identity management system. Subtyped into PARTY_IDENTIFIED and PARTY_SELF.


Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 external_ref : PARTY_REF0..1  -- Optional reference to more detailed demographic or identification information for this party, in an external system. 


Parent Package: generic
Class PARTY_SELF


PARTY_PROXY
   |
   +--PARTY_SELF

Party proxy representing the subject of the record.


Parent Package: generic
Class PARTY_IDENTIFIED


PARTY_PROXY
   |
   +--PARTY_IDENTIFIED

Direct Subclassifiers:
       PARTY_RELATED


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 identifiers : List<DV_IDENTIFIER> 0..1  --  One or more formal identifiers (possibly computable). 
 name : String 0..1  --  Optional human-readable name (in String form). 


Parent Package: generic
Class PARTY_RELATED


PARTY_IDENTIFIED
   |
   +--PARTY_RELATED

Relationship of subject of this ENTRY to the subject of the record. May be coded. If it is the atient, coded as “self”.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 relationship : DV_CODED_TEXT  --   

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 party : PARTY_REF0..1  --  

Constraints
NameExpression
Relationship_validinv: relationship <> Void and terminology(Terminology_id_openehr). has_code_for_group_id(Group_id_subject_relationship, relationship. defining_code) 


Parent Package: generic
Class ATTESTATION


AUDIT_DETAILS
   |
   +--ATTESTATION

Record an attestation of a party (the committer) to item(s) of record content. The type of attestation is


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 attested_view : DV_MULTIMEDIA  --  Optional visual representation of content attested e.g. screen image. 
 is_pending : Boolean  --  True if this attestation is outstanding; False means it has been completed. 
 items : Set<DV_EHR_URI> 0..1  --  Items attested, expressed as fully qualified runtime paths to the items in question. Although not recommended, these may include fine-grained items which have been attested in some other system. Otherwise it is assumed to be for the entire VERSION with which it is associated. 
 proof : String 0..1  --  Proof of attestation. 
 reason : DV_TEXT  --  Reason of this attestation. Optionally coded by the openEHR Terminology group “attestation reason”; includes values like “authorisation”, “witness” etc. 

Constraints
NameExpression
Reason_validinv: reason <> Void and (reason. generating_type.is_equal('DV_CODED_TEXT') implies terminology(Terminology_id_openehr).has_code_for_group_id (Group_id_attestation_reason, reason.defining_code)) 
Items_validinv: items <> Void implies not items.is_empty 


Parent Package: generic
Class AUDIT_DETAILS

Direct Subclassifiers:
       ATTESTATION

The set of attributes required to document the committal of an information item to a repository.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 change_type : DV_CODED_TEXT  --  Type of change. Coded using the openEHR Terminology “audit change type” group. 
 description : DV_TEXT 0..1  --  Reason for committal. 
 system_id : String  --  Identity of the system where the change was committed. Ideally this is a machine- and human-processable identifier, but it may not be. 
 time_committed : DV_DATE_TIME  --  Time of committal of the item. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 committer : PARTY_PROXY -- Identity and optional reference into identity management service, of user who committed the item. 

Constraints
NameExpression
Committer_validinv: committer <> Void 
Time_committed_validinv: time_committed <> Void 
System_id_validinv: system_id <> Void and not system_id.is_empty 
Change_type_validinv: change_type<> Void and terminology(Terminology_id_openehr). has_code_for_group_id(Group_id_audit_change_type, change_type.defining_code) 


Parent Package: common
Package :: resource

The common.resource package defines the structure and semantics of the general notion of an online resource which has been created by a human author, and consequently for which natural language is a factor.


Inner Elements
NameType
 AUTHORED_RESOURCEClass
 RESOURCE_DESCRIPTIONClass
 RESOURCE_DESCRIPTION_ITEMClass
 TRANSLATION_DETAILSClass


Parent Package: resource
Class TRANSLATION_DETAILS

Class providing details of a natural language translation.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 accreditation : String  --  Accreditation of translator, usually a national translator’s association id 
 author : Hash<String,String>  --  Translator name and other demographic details 
 language : CODE_PHRASE  --  Language of translation 
 other_details : Hash<String,String> 0..1  --  Any other meta-data 

Constraints
NameExpression
Author_validinv: author <> Void 
Language_validinv: language <> Void and code_set('languages').has(language) 


Parent Package: resource
Class RESOURCE_DESCRIPTION

Defines the descriptive meta-data of a resource.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 lifecycle_state : String  --  Lifecycle state of the resource, typically including states such as: initial, submitted, experimental, awaiting_approval, approved, superseded, obsolete. 
 original_author : Hash<String,String>  --  Original author of this resource, with all relevant details, including organisation. 
 other_contributors : List<String> 0..1  --  Other contributors to the resource, probably listed in “name ” form. 
 other_details : Hash<String,String> 0..1  --  Additional non language-senstive resource meta-data, as a list of name/value pairs. 
 resource_package_uri : String 0..1  --  URI of package to which this resource belongs. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 details : Set<RESOURCE_DESCRIPTION_ITEM>0..1 Details of all parts of resource description that are natural language-dependent. 
 parent_resource : AUTHORED_RESOURCE0..1  -- Reference to owning resource. 

Constraints
NameExpression
Details_validinv: details <> Void and not details.is_empty 
Parent_resource_validinv: parent_resource <> Void implies parent_resource.description = Current 
Original_author_validinv: original_author <> Void and not original_author.is_empty 
Language_validinv: details.for_all (d | parent_resource.languages_available.has(d.language)) 
Lifecycle_state_valided2inv: lifecycle_state <> Void and not lifecycle_state.is_empty 


Parent Package: resource
Class AUTHORED_RESOURCE{Abstract}

Direct Subclassifiers:
       ARCHETYPE

Abstract idea of an online resource created by a human author.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 is_controlled : Boolean 0..1  --  True if this resource is under any kind of change control (even file copying), in which case revision history is created. 
 original_language : CODE_PHRASE  --  Language in which this resource was initially authored. Although there is no language primacy of resources overall, the language of original authoring is required to ensure natural language translations can preserve quality. Language is relevant in both the description and ontology sections. 
 translations : Hash<TRANSLATION_DETAILS, String> 0..1  --  List of details for each natural translation made of this resource, keyed by language. For each translation listed here, there must be corresponding sections in all language-dependent parts of the resource. The original_language does not appear in this list. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 revision_history : REVISION_HISTORY0..1  -- The revision history of the resource. Only required if is_controlled = True (avoids large revision histories for informal or private editing situations). 
 description : RESOURCE_DESCRIPTION0..1  -- Description and lifecycle information of the resource. 

Operations
SignatureConstraintsDocumentation
 current_revision() : String 
post: Result = revision_history.most_recent_version  
Most recent revision in revision_history if is_controlled else “(uncontrolled)”. 
 languages_available() : Set<String>  Total set of languages available in this resource, derived from original_language and translations. 

Constraints
NameExpression
Revision_history_validinv: is_controlled xor revision_history = Void 
Current_revision_validinv: current_revision <> Void and not is_controlled implies current_revision.is_equal('(uncontrolled)') 
Original_language_validinv: original_language <> void and code_set(Code_set_id_languages).has_code(original_language.as_string) 
Languages_available_validinv: languages_available <> Void and languages_available.has(original_language) 
Translations_validinv: translations <> Void implies (not translations.is_empty and not translations.has(orginal_language.code_string)) 
Description_validinv: translations <> Void implies (description.details.for_all(d | translations.has_key(d.language.code_string))) 


Parent Package: resource
Class RESOURCE_DESCRIPTION_ITEM

Language-specific detail of resource description. When a resource is translated for use in another language environment, each RESOURCE_DESCRIPTION_ITEM needs to be copied and translated into the new language.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 copyright : String 0..1  --  Optional copyright statement for the resource as a knowledge resource. 
 keywords : List<String> 0..1  --  Keywords which characterise this resource, used e.g. for indexing and searching. 
 language : CODE_PHRASE  --  The localised language in which the items in this description item are written. Coded from openEHR Code Set “languages”. 
 misuse : String 0..1  --  Description of any misuses of the resource, i.e. contexts in which it should not be used. 
 original_resource_uri : Hash<String,String> 0..1  --  URIs of original clinical document(s) or description of which resource is a formalisation, in the language of this description item; keyed by meaning. 
 other_details : Hash<String,String> 0..1  --  Additional language-senstive resource metadata, as a list of name/value pairs. 
 purpose : String  --  Purpose of the resource. 
 use : String 0..1  --  Description of the uses of the resource, i.e. contexts in which it could be used. 

Constraints
NameExpression
copyright_validinv: copyright <> Void implies not copyright.is_empty 
misuse_validinv: misuse <> Void implies not misuse.is_empty 
use_validinv: use <> Void implies not use.is_empty 
purpose_validinv: purpose <> Void and not purpose.is_empty 
Language_validinv: language <> Void and code_set('languages').has(language) 


Parent Package: rm
Package :: composition

The Composition is the primary ‘data container’ in the openEHR EHR and is the root point of clinical content. Instances of the Composition class can be considered as self-standing data aggregations, or documents in a document-oriented system (similar to HL7 CDA Documents). The key information in a COMPOSITION is found in its content, context, and composer attributes. The majority of the use of paths in openEHR is likely to be within Compositions.


Inner Elements
NameType
 COMPOSITIONClass
 EVENT_CONTEXTClass
 contentPackage


Parent Package: composition
Class COMPOSITION


LOCATABLE
   |
   +--COMPOSITION

One version in a VERSIONED_COMPOSITION. A composition is considered the unit of modification of the record, the unit of transmission in record extracts, and the unit of attestation by authorising clinicians. In this latter sense, it may be considered equivalent to a signed document.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 category : DV_CODED_TEXT  --  Indicates what broad category this Composition is belogs to, e.g. “persistent” - of longitudinal validity, “event”, “process” etc. 
 language : CODE_PHRASE  --  Mandatory indicator of the localised language in which this Entry is written. Coded from openEHR Code Set “languages”. 
 territory : CODE_PHRASE  --  Name of territory in which this Composition was written. Coded from openEHR “countries” code set, which is an expression of the ISO 3166 standard. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 context : EVENT_CONTEXT0..1  -- The clinical session context of this Composition, i.e. the contextual attributes of the clinical session. 
 content : Set<CONTENT_ITEM>0..1 0..* The content of this Composition. 
 composer : PARTY_PROXY --  

Operations
SignatureConstraintsDocumentation
 is_persistent() : Boolean  True if category is a “persistent” type, False otherwise. Useful for finding Compositions in an EHR which are guaranteed to be of interest to most users. 

Constraints
NameExpression
Is_archetype_rootinv: is_archetype_root 
Content_validinv: content <> Void implies not content.is_empty 
Composer_validinv: composer <> Void 
Territory_validinv: territory <> Void and code_set(Code_set_id_countries).has_code(territory) 
No_parentinv: parent = Void 
Is_persistent_validityinv: is_persistent implies context = Void 
Category_validityinv: category <> Void and terminology(Terminology_id_openehr). has_code_for_group_id(Group_id_composition_category, category. defining_code) 
language_validinv: language <> Void and code_set(Code_set_id_languages).has_code(language)  


Parent Package: composition
Class EVENT_CONTEXT


PATHABLE
   |
   +--EVENT_CONTEXT

Documents the context information of a healthcare event involving the subject of care and the health system. The context information recorded here are independent of the attributes recorded in the version audit, which document the “system interaction” context, i.e. the context of a user interacting with the health record system. Healthcare events include patient contacts, and any other business activity, such as pathology investigations which take place on behalf of the patient.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 end_time : DV_DATE_TIME 0..1  --  Optional end time of the clinical session. 
 location : String 0..1  --  The actual location where the session occurred, e.g. “microbiol lab 2”, “home”, “ward A3” and so on. 
 other_context : ITEM_STRUCTURE 0..1  --  Other optional context which will be archetyped. 
 setting : DV_CODED_TEXT  --  The setting in which the clinical session took place. Coded using the openEHR Terminology, “setting” group. 
 start_time : DV_DATE_TIME  --  Start time of the clinical session or other kind of event during which a provider performs a service of any kind for the patient. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 health_care_facility : PARTY_REF0..1  --  
 composer : PARTY_REF --  
 participations : Set<PARTICIPATION>0..1 0..* Parties involved in the healthcare event. These would normally include the physician(s) and often the patient (but not the latter if the clinical session is a pathology test for example). 
 health_care_facility : PARTY_IDENTIFIED0..1  -- The health care facility under whose care the event took place. This is the most specific workgroup or delivery unit within a care delivery enterprise that has an official identifier in the health system, and can be used to ensure medico-legal accountability. 

Constraints
NameExpression
setting_validinv: setting <> Void and Terminology(Terminology_id_openehr).has_code_for_group_id (Group_id_setting, setting.defining_code) 
participations_validityinv: participations <> Void implies not participations. is_empty 
start_time_validinv: start_time <> Void 
location_validinv: location <> Void implies not location.is_empty  


Parent Package: composition
Package :: content


Inner Elements
NameType
 CONTENT_ITEMClass
 entryPackage
 navigationPackage


Parent Package: content
Class CONTENT_ITEM{Abstract}


LOCATABLE
   |
   +--CONTENT_ITEM

Direct Subclassifiers:
       SECTION, ENTRY, GENERIC_ENTRY

Abstract ancestor of all concrete content types.


Parent Package: content
Package :: entry

All information which is created in the openEHR health record is expressed as an instance of a class in the entry package, containing the ENTRY class and a number of descendants. An ENTRY instance is logically a single ‘clinical statement’, and may be a single short narrative phrase, but may also contain a significant amount of data, e.g. an entire microbiology result, a psychiatric examination, a complex prescription. In terms of actual content, the Entry classes are the most important in the openEHR EHR Information Model, since they define the semantics of all the ‘hard’ information in the record. They are intended to be achetyped, and in fact, archetypes for Entries make up the vast majority of important clinical archetypes defined.


Inner Elements
NameType
 ACTIONClass
 ACTIVITYClass
 ADMIN_ENTRYClass
 CARE_ENTRYClass
 ENTRYClass
 EVALUATIONClass
 INSTRUCTIONClass
 INSTRUCTION_DETAILSClass
 ISM_TRANSITIONClass
 OBSERVATIONClass


Parent Package: entry
Class OBSERVATION


CARE_ENTRY
   |
   +--OBSERVATION

Entry subtype for all clinical data in the past or present, i.e. which (by the time it is recorded) has already occurred. OBSERVATION data is expressed using the class HISTORY, which guarantees that it is situated in time.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 data : HISTORY  --  The data of this observation, in the form of a history of values which may be of any complexity. 
 state : HISTORY 0..1  --  Optional recording of the state of subject of this observation during the observation process, in the form of a separate history of values which may be of any complexity. State may also be recorded within the History of the data attribute. 

Constraints
NameExpression
Data_validinv: data Void 


Parent Package: entry
Class EVALUATION


ENTRY, CARE_ENTRY
   |
   +--EVALUATION

Entry type for evaluation statements.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 data : ITEM_STRUCTURE  --  The data of this evaluation, in the form of a spatial data structure. 

Constraints
NameExpression
Data_validinv: data <> Void 


Parent Package: entry
Class INSTRUCTION


CARE_ENTRY, ENTRY
   |
   +--INSTRUCTION

Used to specify actions in the future. Enables simple and complex specifications to be expressed, including in a fully-computable workflow form.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 expiry_time : DV_DATE_TIME 0..1  --  Optional expiry date/time to assist determination of when an Instruction can be assumed to have expired. This helps prevent false listing of Instructions as Active when they clearly must have been terminated in some way or other. 
 narrative : DV_TEXT  --  Mandatory human-readable version of what the Instruction is about. 
 wf_definition : DV_PARSABLE 0..1  --  Optional workflow engine executable expression of the Instruction. 

Attributes from Associations
SignatureOptionalityMultiplicityDocumentation
 activities : Set<ACTIVITY>0..1 List of all activities in Instruction. 

Constraints
NameExpression
Narrative_validinv: narrative <> Void 
Activities_validinv: activities <> Void implies not activities.is_empty 


Parent Package: entry
Class ENTRY{Abstract}


CONTENT_ITEM
   |
   +--ENTRY

Direct Subclassifiers:
       CARE_ENTRY, EVALUATION, INSTRUCTION, ADMIN_ENTRY

The abstract parent of all ENTRY subtypes. An ENTRY is the root of a logical item of “hard” clinical information created in the “clinical statement” context, within a clinical session. There can be numerous such contexts in a clinical session. Observations and other Entry types only ever document information captured/created in the event documented by the enclosing Composition. An ENTRY is also the minimal unit of information any query should return, since a whole ENTRY (including subparts) records spatial structure, timing information, and contextual information, as well as the subject and generator of the information.


Attributes
SignatureOptionalityMultiplicityConstantDocumentation
 encoding : CODE_PHRASE  --  Name of character set in which text values in this Entry are encoded. Coded from openEHR Code Set “character sets”. 
 language : CODE_PHRASE  --  Mandatory indicator of the localised language in which this Entry is written. Coded from openEHR Code Set “languages”. 
 other_participations : List<PARTICIPATION> 0..1  --  Other participations at ENTRY level. 
 provider : PARTY_PROXY 0..1  --  Optional identification of provider of the informatoin in this ENTRY, which might be: • the patient • a patient agent, e.g. parent, guardian • the clinician • a device or software Generally only used when the recorder needs to make it explicit. Otherwise, Composition composer and other participants are assumed. 
 subject : PARTY_PROXY  --  Id of human subject of this ENTRY, e.g.: • organ donor • foetus • a family member • another clinically relevant person. 
 workflow_id : OBJECT_REF 0..1  --  Identifier of externally held workflow engine data for this workflow execution, for this subject of care. 

Operations
SignatureConstraintsDocumentation
 subject_is_self() : Boolean  Returns True if this Entry is about the subject of the EHR, in which case the subject attribute is of type PARTY_SELF. 

Constraints
NameExpression
Subject_validityinv: subject_is_self implies subject.generating_type = 'PARTY_SELF' 
Archetype_root_pointinv: is_archetype_root 
Other_participations_validinv: other_participations <> Void implies not other_participations.is_empty  
Language_validinv: language <> Void and code_set(Code_set_id_languages).has_code(language)  
Encoding_validinv: encoding <> Void and code_set(Code_set_id_character_sets).has_code(encoding)  


Parent Package: entry
Class ADMIN_ENTRY