Subject: Re: [xsl] re-ordering an instance to match a schema From: S Woodside <sbwoodside@xxxxxxxxx> Date: Wed, 14 May 2003 18:15:33 -0400 |
Hi Simon,
At 02:32 PM 5/14/2003, you wrote:Is there XSLT out there, that I can use, that will take an instance and a schema and re-order the instance to match the schema? Does that make sense?
Two things that can help us answer this question:
1. Are we talking arbitrary RNG schemas, or some subset thereof?
2. By "reorder the instance to match the schema", we are talking about the order declared by the schema to be a valid order, or the order of the declarations? (The former, I take it. But this is why the first question is important.)
Seeing a sample of input (in this case, both inputs) and desired output would, as always, be a big help.
<element name="contact"> <zeroOrMore> <choice> <element name="phone"> <optional> <attribute name="location"> <choice> <value> home </value> <value> work </value> <value> mobile </value> </choice> </attribute> </optional> <text /> </element> <element name="fax"> <optional> <attribute name="location"> <choice> <value> home </value> <value> work </value> </choice> </attribute> </optional> <text /> </element> <element name="pager"> <text /> </element> <element name="email"> <text /> </element> <element name="url"> <text /> </element> <element name="instantMessage"> <optional> <attribute name="service" /> </optional> <text /> </element> </choice> </zeroOrMore> </element>
<contact> <url>http://www.simonwoodside.com/<url> <email>sbwoodside@xxxxxxxxx</email> <phone location="work">555-1212</phone> <fax>555-1111</fax> </contact>
<contact> <phone location="work">555-1212</phone> <fax>555-1111</fax> <email>sbwoodside@xxxxxxxxx</email> <url>http://www.simonwoodside.com/<url> </contact>
-- www.simonwoodside.com -- 99% Devil, 1% Angel
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] re-ordering an instance t, Wendell Piez | Thread | Re: [xsl] re-ordering an instance t, S Woodside |
Re: [xsl] xsl fo - problem opening , J.Pietschmann | Date | [xsl] xsl:copy-of misuse?, Holbrook, R Cody (Co |
Month |