W3C home > Mailing lists > Public > xmlschema-dev@w3.org > October 2003

Nested Substitutiongroups, how to?

From: Svend Bent Nielsen <jawsoap@hotmail.com>
Date: Tue, 14 Oct 2003 10:52:53 +0000
To: xmlschema-dev@w3.org
Message-ID: <BAY7-F114jCD2ELfWCq0000edb7@hotmail.com>

Hello all,

I have just now joined this list and have of course a question.

I am trying to convert a dtd to schema, and have the following problem:
In the DTD I have this:

<!ENTITY SmallGroup "A|B|C|D">
<!ENTITY LargeGroup "X|Y|Z|%LargeGroup;">

<!ELEMENT F (#PCDATA|%SmallGroup;)*>
<!ELEMENT G (#PCDATA|%LargeGroup;)*>

I am trying to convert it to schema, and can do something like:

<xs:element name="_SmallGroup" abstract="true"/>

<xs:element name="A" substitutionGroup="_SmallGroup"/>
<xs:element name="B" substitutionGroup="_SmallGroup"/>
<xs:element name="C" substitutionGroup="_SmallGroup"/>
<xs:element name="D" substitutionGroup="_SmallGroup"/>

But to have something like LargeGroup, which contains all of SmallGroup plus 
some other elements, how would I do this?

Hope this is possible.

Svend Bent Nielsen

Få alle de nye og sjove ikoner med MSN Messenger http://messenger.msn.dk
Received on Tuesday, 14 October 2003 06:54:42 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:56:03 UTC