Possible error in grammar regarding to description in archetype, etc.

Description

When I read the AOM document, I see at: http://www.openehr.org/releases/AM/latest/docs/AOM2/AOM2.html#_the_archetype_package

That Authored_Archetype is derived from Authored_Resource, and in Authored_Resource, "description" has a occurrence of 0..1., so it is not obligatory. Authored_Archetype is the base-class for Template and Archetype in the grammar, so description in the grammar should not be obligatory and should therefore carry a question-mark to indicate that it may occur zero or one time.

Environment

None

Activity

Show:
Thomas Beale
May 16, 2016, 8:55 AM

I agree it is slightly confusing when comparing the ADL2 grammar and AOM2 model. But they are both correct. The 'archetype' production rule in the grammar actually corresponds to the AUTHORED_ARCHETYPE class in the AOM. I have renamed this rule to 'authored_archetype' in the grammar to match.

The 'description' attribute is optional in AIUTHORED_RESOURCE in the AOM, but you will see that in the AUTHORED_ARCHETYPE class definition, an invariant is added to make it mandatory - http://www.openehr.org/releases/AM/latest/docs/AOM2/AOM2.html#_authored_archetype_class

In theory we should add a similar invariant to prohibit 'description' in TEMPLATE_OVERLAY.

Bert Verhees
May 16, 2016, 9:33 AM

Sorry, I overlooked the invariant-clause in AUTHORED_ARCHETYPE.

By the way, I think it is incorrect to add the invariant to prohibit 'description' in TEMPLATE_OVERLAY because TEMPLATE_OVERLAY does not inherit from AUTHORED_RESOURCE

I think you can close this PR

Thomas Beale
May 16, 2016, 9:38 AM

Re: TEMPLATE_OVERLAY; yes you are correct; I was misreading the model.

Reporter

Bert Verhees

Labels

None

Components

Affects versions

Priority

Minor
Configure