RE: Didier's lab report
It's entirely feasible for an XSLT processor to recognize at compile time any calls of document() that can be resolved statically, and to generate code in the compiled stylesheet that causes the download of these documents to start asynchronously as soon as stylesheet execution starts. This isn't true in the example cited, because the absolute URI of the required document depends on the base URI of the current node in the source document. Mike Kay > -----Original Message----- > From: Didier PH Martin [SMTP:martind@n...] > Sent: Wednesday, July 26, 2000 10:42 PM > To: Arnold, Curt; xml-dev@x... > Subject: RE: Didier's lab report > > Hi Curt, > > Curt said: > It should be possible for an XSLT implementation to use asynchronous > retrieval of document() using variables. > > Say, if you had something like this > > <xsl:transform ....> > > <xsl:variable name="doc1" select="document('doc1.xml',.)"/> > <xsl:variable name="doc2" select="document('doc2.xml',.)"/> > <xsl:variable name="doc3" select="document('doc3.xml',.)"/> > > > <xsl:template match="/"> > <xsl:apply-templates/> > </xsl:template> > > ... > </xsl:transform> > > The declaration of the variable could start the download/parsing process > but > not block further execution. Only when the variable was used in an > expression > would the template evaluation thread need to block. > > I do not know if any of the existing processors implement this type of > behavior, > however it would not seem to require any changes to XSLT to approach the > performance that you estimated for XInclude. > > Didier replies: > If I understand you well, this would imply first that we are allowed to > use > as a variable an external document tree. Then, if the XSLT processor > recognizes that the select is a document() function, that the XSLT > processor > starts a thread to set the variable to a tree (will take as much time as > the > external server will take to return the resulting document). After having > started a thread, the XSLT engine would go to the next variable > assignment. > > Cheers > Didier PH Martin > ---------------------------------------------- > Email: martind@n... > Conferences: xml devconf 2000 (http://www.xmldevconf2000.com) > Book: XML Professional (http://www.wrox.com) > column: Style Matters (http://www.xml.com) > Products: http://www.netfolder.com
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format