Hi Andrew If the language only makes positive structural statements, such as standard 3gl o-o paradigms, then specialization cannot be done by restriction - while there's nothing stopping it, there's no way to express it. (Though reference Heath's email - there's various ways to actually do it, but many of them result in ill-formed models, just the compiler doesn't know how to stop them, therefore they are "legal")
If the language is able to make constraint statements, then specialization can be done by both restriction and extension - but restrictions in the generalization will prohibit some forms or instances of both extension and restriction in the specializations. ADL is able to make both positive structural statements and constraint statements, so it's able to support specialization by extension and restriction. But I think, due to the nature of ADL, that there is no computationally provable answer to whether any given specialisation is properly formed (at least in the general case). Many of the stupid things about XML Schema arise because they have a requirement (I think), that there must be a computationally provable answer. Grahame Andrew Goodchild wrote: > I would only hope that that is what is intended. However, the semantics at > the moment that appears to be supported by the editor implies that archetype > specialization is nothing more that "cut and paste" style semantics. We will > have to wait for the answer from Tom and Sam. > > Also, I am wondering if archetype specialization only supports restriction > or extension or both? > > -Andrew > > > -----Original Message----- > From: owner-openehr-technical at openehr.org > [mailto:owner-openehr-technical at openehr.org] On Behalf Of Grahame Grieve > Sent: Thursday, 26 May 2005 12:08 PM > To: openehr-technical at openehr.org > Subject: Re: The semantics of archetype Specialization > > Hi Andrew > > Well, I'll defer to Tom or Sam. But from a > computational perspective, what else could make sense? > > Grahame > > > Andrew Goodchild wrote: > >>Thanks Grahame, >> >>The UML specs definition of specialization matches what I thought it had >>meant. >> >>I guess what I would like to understand is whether such a definition is > > true > >>or not for archetypes? >> >>Is specialization in archetypes meant to support the definition you > > provided > >>and the archetype editor is missing some functionality to ensure that only >>correctly specialized archetypes can be built? >> >>- or - >> >>Is it that archetypes and the editor supports some new semantics around >>specialization that I don't quite understand yet? >> >>I am sure Sam or Tom could shed some light on this ... >> >>Cheers, Andrew >> >> >>-----Original Message----- >>From: owner-openehr-technical at openehr.org >>[mailto:owner-openehr-technical at openehr.org] On Behalf Of Grahame Grieve >>Sent: Thursday, 26 May 2005 10:57 AM >>To: openehr-technical at openehr.org >>Subject: Re: The semantics of archetype Specialization >> >>Hi Andrew >> >> >> >>>Does anyone know what it actually means to specialize an archetype? And >> >>what >> >> >>>the rules are? >> >> >>The UML specification offers this definition for generalization: >> >> A taxonomic relationship between a more general element and a >> more specific element. The more specific element is fully consistent >> with the more general element and contains additional information. An >> instance of the more specific element may be used where the more >> general element is allowed >> >>I think that this is a fairly watertight definition and quite relevent >>to your question. >> >> >> >>>I looked at the archetype editor and created a specialized archetype of >>>another. The editor seemed to just copy the parent archetype and then >>>allowed the user to change anything about the archetype. >>> >>>For example, I can now make a mandatory field optional, or I can extend a >>>parent archetype with new mandatory fields that don't exist as optional >>>fields in the parent archetype >> >> >>By the UML definitions, these become "ill-formed" model. >> >>Of course, it's one thing to to state the definition, quite another to >>know how to compute whether a model is ill-formed. >> >>Grahame >> >> >> >>- >>If you have any questions about using this list, >>please send a message to d.lloyd at openehr.org > > > > > - > If you have any questions about using this list, > please send a message to d.lloyd at openehr.org

