W3C home > Mailing lists > Public > www-xml-schema-comments@w3.org > October to December 2000

Adding attributes to lists

From: Jane Hunter <jane@dstc.edu.au>
Date: Mon, 23 Oct 2000 10:12:12 +1000
Message-Id: <200010230012.e9N0Ckc29972@piglet.dstc.edu.au>
To: www-xml-schema-comments@w3.org
For MPEG-7 implementations, we'd like to be able to specify the 
dimensions of a variable-sized array through an attribute added to a 
list. For example:

<simpleType name="listofInteger">
   <list itemType="integer"/>
</simpleType>

<complexType name="nDimIntegerArray">
  <simpleContent>
    <extension base="listOfInteger">
        <attribute ref="mpeg7:dim"/>
    </extension>
  </simpleContent>
</complexType>

<element name="integerMatrix" type="nDimIntegerArray"/>

<integerMatrix mpeg7:dim="2 4">1 2 3 4 5 6 7 8</integerMatrix>

Is this permissable? The primer explicitly says that you cannot create 
new list types from existing list types - does this include adding an 
attribute to an existing list type?

regards,
jane

+-----------------------------+-------------------------------------+
| Jane Hunter                 | Senior Research Scientist           |
| DSTC Pty Ltd                | Distributed Systems Technology CRC  |
| Level 7, GP South           | Tel   : +61 7 3365 4310             |
| University of Queensland    | Fax   : +61 7 3365 4311             |
| Queensland 4072, Australia  | Email : jane@dstc.edu.au            |
+-----------------------------+-------------------------------------+
Received on Sunday, 22 October 2000 20:13:08 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 6 December 2009 18:12:48 GMT