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

Definition of object hierarchies in XML schema

From: Prosi, Rainer 4620 PPE-WT <Rainer.Prosi@de.heidelberg.com>
Date: Thu, 26 Oct 2000 19:23:22 +0200
Message-ID: <1F41768842F3D311A5DA0000D11E5E98758879@kiems02.ger05.heidelberg.com>
To: "'www-xml-schema-comments@w3.org'" <www-xml-schema-comments@w3.org>
Hi Folks;

I am using XML as a data container and need "object-oriented" data types
that allow overriding of defaults. The way this is done is that an element
may contain nested elements of itself, e.g.

<A att1="a" att2="b">
  <A leaf="1" att1="aa" att3="c1"/>
  <A leaf="2" att3="c2"/>

this is semantically equivalent to 
<A att1="aa" att2="b" att3="c1"/>
<A att1="a" att2="b" att3="c2"/>

Is there any way in XML schema to specify that each leaf of the tree must
have all three attributes att1, att2, att3 but not each individual node ar
am I forced to simply make each attribute optional?

Rainer Prosi
Heidelberger Druckmaschinen AG
Received on Thursday, 26 October 2000 13:23:36 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 23:08:49 UTC