On Wed, 2004-09-08 at 13:03, Norman Walsh wrote: > Dan, > > I don't believe there are any tests of XInclude used with XML Schema > or XSLT processors. I don't know of any processors that (directly) > support XInclude in schema documents or stylesheet documents. > (Indirect support through pipeline languages such as sxpipe is > certainly possible.) > > Schemas can certainly be written that validate the occurence of > xi:include elements in input documents (assuming that the input > document was not subject to XInclude processing, of course). > Similarly, stylesheets can be written that will transform xi:include > elements or produce them in the transformed result. Would you (plural) please write some and put them in a test suite? > > An XInclude in a schema or stylesheet document, if the document was > subject to XInclude processing before the schema or stylesheet > processor encountered it, would behave exactly like an external parsed > entity. > > <xsl:stylesheet xmlns:xsl="..."> > <xsl:output method="xml"/> > <xi:include xmlns:xi="..." href="someDocument.xsl"/> > </xsl:stylesheet> > > is effectively the same as > > <!DOCTYPE xsl:stylesheet [ > <!ENTITY someDocument SYSTEM "someDocument.xsl"> > ]> > <xsl:stylesheet xmlns:xsl="..."> > <xsl:output method="xml"/> > &someDocument; > </xsl:stylesheet> That seems worth capturing in a test. > This is distinct from the xsl:include element (or the xsd:include > element) which performs additional, application-specific semantic > processing *in addition to* performing a kind of textual inclusion. > > Had XInclude existed when XML Schema or XSLT were under development, I > think it *could* have been used instead, but it cannot be used instead > now. That's another assertion that seems to merit a test. > In particular: > > - including one stylesheet "style.xsl" in another with XInclude > would likely result in a xsl:stylesheet element as a child of the > "including" xsl:stylesheet which would be an error. > > - including one stylesheet "style.xsl/*/*" in another with XInclude > would not inform the including stylesheet of any attribute values > that might have been set on the included stylesheet's root element. > That could produce quite different semantics than xsl:include. > > I hope this helps clarify the situation. Well, yes, but I'm afraid it makes it clear that the situation is not, yet, as it should be. > Be seeing you, > norm -- Dan Connolly, W3C http://www.w3.org/People/Connolly/Received on Friday, 10 September 2004 22:16:13 GMT
This archive was generated by hypermail 2.2.0 + w3c-0.30 : Thursday, 9 June 2005 12:16:10 GMT