XMI 1.2 NO IDEA Avatar
  1. OMG Issue

XMI12 — General question to "3.6.4 Inheritance Specification"

  • Key: XMI12-8
  • Legacy Issue Number: 5549
  • Status: open  
  • Source: Anonymous
  • Summary:

    General question to "3.6.4 Inheritance Specification": Why we declare all
    XML elements and XML attributes direct under class C0 declaration and not as
    parameter entity named like:

    <!ENTITY % C0.elem "C0.a0">
    <!ENTITY % C0.ref "C0.r0">
    <!ENTITY % C0.comp "C0.comp0">

    <!ENTITY % "C0.attr
    a0 CDATA #IMPLIED
    a1 CDATA #IMPLIED
    r0 CDATA #IMPLIED
    r1 CDATA #IMPLIED
    >

    and then:
    <!ELEMENT C0 (%C0.elem; | XMI.extension | %C0.ref; | %C0.comp*>
    <!ATTLIST C0
    %C0.attr;
    %XMI.element.att;
    %XMI.link.att;"
    >

    and for third subclass analogical:

    <!ELEMENT C3
    (%C0.elem; | %C1.elem; | %C2.elem | %C3.elem | XMI.extension |
    %C0.ref; | %C1.ref; | %C2.ref; | %C3.ref |
    %C0.comp | %C1.comp | %C2.comp | %C3.comp )*>

    • >
      <!ATTLIST C3
      %C0.attr;
      %C1.attr;
      %C2.attr;
      %C3.attr;
      %XMI.element.att;
      %XMI.link.att;"
      >

    Imagine how short would be the DTD of UML in such an format.

    It can be even shorter if we declare only one entity for all subelements
    like:

    <!ENTITY % C0.elem "C0.a0 | C0.r0 | C0.comp0 | XMI.extension">
    <!ENTITY % C1.elem "%C0.elem | ... my own elements without XMI.extension ...
    ">

    and than any n-subclass:

    <!ENTITY Cn "%C'n-1'.elem | ... my own elements without XMI.extension ...">
    <!ELEMENT Cn (%Cn.elem*>

    analogical implified form for ATTLIST is applicable, the last example could
    be:

    <!ENTITY Cn.attr "
    %C'n-1'.attr
    ... my own elements without %XMI.element.att; and %XMI.link.att; ... ">
    <!ATTLIST Cn
    %Cn.attr;
    >

  • Reported: XMI 1.1 — Mon, 8 Jul 2002 04:00 GMT
  • Updated: Wed, 11 Mar 2015 11:15 GMT