W3C home > Mailing lists > Public > xmlschema-dev@w3.org > December 2001

Generating dynamic "choice" content

From: Piccand Régis <regis.piccand@imtf.ch>
Date: Mon, 3 Dec 2001 12:20:38 +0100
Message-ID: <DF7EC83D7AFBD411965B0008C7596EC53ED48C@imtfexchange.imtf.ch>
To: xmlschema-dev@w3.org
Hi all,

I'm pretty new to XML-schema and am wondering about dynamical generation of

Let's assume I want to dynamically fill or add new elements in a choice
list, as follows :

<!-- extract from XML Schemas tutorial - Roger Costello - available at
<xsd:element name="transportation">
			<xsd:element name="train" type="xsd:string"/>
			<xsd:element name="plane" type="xsd:string"/>
			<xsd:element name="automobile" type="xsd:string"/>

The "choice" elements (train, plane, automobile) should be read from a DB
and dynamically added ; the complete element definition (type, minOccurs,
maxOccurs, etc.) would be read from the DB too.

What options do I have to achieve this ? 

For now, the only option I see is to programmatically generate a schema for
this type and then ref it from my main schema.

I would be very grateful if any of you could give me some "pointers" to
available documents/products involving dynamic generation of schemas.

Thanks a lot in advance for your help and best regards

Received on Monday, 3 December 2001 06:26:40 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 14:55:54 UTC