W3C home > Mailing lists > Public > public-xml-processing-model-wg@w3.org > February 2006

The iterator case

From: Norman Walsh <Norman.Walsh@Sun.COM>
Date: Thu, 16 Feb 2006 15:25:17 -0500
To: public-xml-processing-model-wg@w3.org
Message-ID: <8764nfxd8y.fsf@nwalsh.com>
Multiple inputs and multiple outputs lead immediately to the iterator
case. I'm not sure what to do about that.

The use case:

  Run "xslt" over book.xml. This will produce ch1.html, ch2.html, ...
  Run "tidy" over "ch1.html", "ch2.html", ...

The number (and name) of the outputs in step one depends on the input,
and of course I want the pipeline to be reusable, so how do we do

One solution is to change the stylesheet so that it produces a single


then you could say:

  <p:stage name="xslt">
    <p:param name="stylesheet" href="..."/>
  <p:stage name="tidy"/>
  <p:stage name="splitter"/>

But I'm not sure that's a practical solution.

Another idea is to say that each stage must report to the processor
all of the infosets that it created. Then an iterator could be

  <p:stage name="xslt">
    <p:param name="stylesheet" href="..."/>

  <p:stage name="iterate" anonymous="no">
    <p:stage name="tidy"/>

Where the iterate stage applies the stages it contains to each of the
outputs from the previous stage (optionally only the anonymous
outputs) in turn and produces as its output a set of infosets.

This runs afoul of my immutability idea though, unless the iterator
has some way of changing the names.

I suppose it could always produce anonymous infosets and then the
problem of naming them is mine to solve (using a PI in each one or

There's also the question of what it means for an iterator to produce

  <p:stage name="xslt">
    <p:param name="stylesheet" href="some-fo-stylesheet.xsl"/>

  <p:stage name="iterate" anonymous="no">
    <p:stage name="fotopdf"/>


                                        Be seeing you,

Norman.Walsh@Sun.COM / XML Standards Architect / Sun Microsystems, Inc.
NOTICE: This email message is for the sole use of the intended
recipient(s) and may contain confidential and privileged information.
Any unauthorized review, use, disclosure or distribution is prohibited.
If you are not the intended recipient, please contact the sender by
reply email and destroy all copies of the original message.

Received on Thursday, 16 February 2006 20:25:38 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:32:39 UTC