On Fri, 2008-07-04 Peter Gummer wrote:

>         Now I need to be clear about something ;-)
>         
>         I'm 99% certain, Thomas, that Tim is talking about circular
>         references in 
>         the class model, not in the instance graph.

True.


>         Apparently it gives the Python interpreter an apoplexy when it
>         tries to resolve references that it has discovered yet. But as
>         I mentioned in my earlier email, a bit of googling suggests
>         that Python does have ways of working around this.
>         
>         Let's see what Tim thinks.
>         


Let's see if I can add some context and explain my complaint a bit
better.  

An Archetype instance is a container and it has 6 items in it.  Some are
required, some optional. Some of those are containers as well. You can
visualize this by thinking of a directory tree:

Archetype
  adl_version
  archetype-id
  uid
  concept
  parent_archetype_id
  definition
  ontology
  invariants
  revision_history (inherited)

Sticking with the ontology issue:

Archetype
  adl_version
  archetype-id
  uid
  concept
  parent_archetype_id
  definition
  ontology
    terminologies_available
    specialisation_depth
    term_codes
    constraint_codes
    term_attribute_names
    parent_archetype_id
  invariants
  revision_history (inherited)


The issue here is the REQUIRED attribute parent_archetype_id. The
description is; Archetype which owns this ontology. Intuitively (to me
anyway) this would indicate that I would assign the OID of the parent
Archetype to this attribute.  However, the specifications call for the
attribute to be of the type 'Archetype' and it can't be just any
archetype, it is supposed to be the Archetype containing this ontology.
so I would have a repeating tree like this:

Archetype
  adl_version
  archetype-id
  uid
  concept
  parent_archetype_id
  definition
  ontology
    terminologies_available
    specialisation_depth
    term_codes
    constraint_codes
    term_attribute_names
    parent_archetype_id
      Archetype
                  adl_version
                  archetype-id
                  uid
                  concept
                  parent_archetype_id
                  definition
                  ontology
                    terminologies_available
                    specialisation_depth
                    term_codes
                    constraint_codes
                    term_attribute_names
                    parent_archetype_id
                      ... (repeat infinitely)  
                  invariants
                  revision_history (inherited)
  invariants
  revision_history (inherited)

      

So my suggestion is that ARCHETYPE.ontology.parent_archetype_id be of a
'type' that represents the OID of the parent and NOT the parent itself.


Cheers,
Tim




-------------- next part --------------
A non-text attachment was scrubbed...
Name: Displayemail.gif
Type: image/gif
Size: 4274 bytes
Desc: not available
URL: 
<http://lists.openehr.org/mailman/private/openehr-technical_lists.openehr.org/attachments/20080704/8f2c65b6/attachment.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: 
<http://lists.openehr.org/mailman/private/openehr-technical_lists.openehr.org/attachments/20080704/8f2c65b6/attachment.asc>

Reply via email to