Hi, I’m creating a template from the Encounter archetype using the TD.
That archetype has a slot in the compo.context.other_context. I don’t use that slot so I don’t want it to appear in my final OPT, but I couldn’t find any way in the TD to let me remove that node or put 0..0 on the cardinality, so the exported OPT has the slot.
Is there any way to do this? Maybe other OPT designers?
My understanding is that ADL 1.4 does not formally support slot closures or indeed setting ocurrences of any element to 0 in specialisations/templates.
Certainly not supported in the openEHR Archetype Editor.
Looking at the current AOM, the ARCHETYPE_SLOT has an occurrences attribute, I think that specifying 0..0 occurrences is legal for ADL 1.4, that way I can “remove” the slot.
Also this is compatible with the node occurrences in the Encounter archetype because is 0..*:
As far as I understand it, the AOM/ADL 2 “close” statement avoids including further archetypes into a slot, but do no remove it. To do that, we have to put its occurrences to 0..0, which is perfectly legal in AOM/ADL 1.4 (unless the original slot has a minimal occurrence >=1, of course).
It makes perfect sense to me. A slot is part of the model. The constraint mechanisms of ADL work on the types of RM. Closing a slot or setting occurrence to 0 would both leave the model intact but constrain the set of instances compatible with the model. I’d classify this as further constraining the model.
Removing the slot would create another model, or at least that is how I’d see it.