[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Re: xslt 3.0 possible feature - some sort of coll

Subject: Re: Re: xslt 3.0 possible feature - some sort of collection to help when streaming
From: Michael Kay <mike@xxxxxxxxxxxx>
Date: Fri, 11 Mar 2011 08:42:09 +0000
Re:  Re: xslt 3.0 possible feature - some sort of  coll
On 11/03/2011 07:08, Vladimir Nesterovsky wrote:
xsl:iterate works but it's limited to a single level of iteration, as
this way one cannot easily collect output from nested transformations.


Yes, that's correct. The use case for a single recursive tree walk of the input that delivers multiple results was one that the WG found particularly taxing; we tried many different design approaches. The solution currently in the spec (but not yet implemented) is xsl:fork, which essentially allows you to do several traversals of the input tree "in parallel", each delivering a separate result. This could be implemented using multiple threads but it doesn't have to be; the key idea is that there are several activities/processes listening to the same stream of events during a single pass of the input. (I'd love to have a language with native coroutine support for implementing this.) The results of each activity/process (other than the first) will typically need to be buffered in memory so they can be assembled in the right order in the result tree at the end of the input scan - unless of course each activity writes to a different destination using xsl:result-document.


Michael Kay
Saxonica

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.