W3C home > Mailing lists > Public > xproc-dev@w3.org > March 2009

writing xsl:result-document results to disk

From: James Sulak <jsulak@gmail.com>
Date: Tue, 3 Mar 2009 12:46:03 -0600
Message-ID: <7cb78b3b0903031046h66af4bdat4e43fe848d94b7dd@mail.gmail.com>
To: XProc Dev <xproc-dev@w3.org>
Hello all,

If I call a transform using p:xslt, and that transform attempts to use
multiple <xsl:result-document />s to write documents to disk, these
documents are not actually written to disk.  Instead, the sequence of
documents is made available on the "secondary" output port of p:xslt.
This is true even if the <xsl:result-document /> element has an @href
attribute.

Is this the intended behavior, or should xsl:result-document be
allowed to write to disk?  I don't see in the spec where it specifies
one way or another.  For the current problem I'm facing, I'd like it
to, but I can see arguments against it.

Example pipeline below.

Thanks,

-James



<p:declare-step xmlns:p="http://www.w3.org/ns/xproc"
xmlns:c="http://www.w3.org/ns/xproc-step"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" >
    <p:input port="source" >
        <p:inline>
            <test/>
        </p:inline>
    </p:input>
    <p:input port="parameters" kind="parameter" />
    <p:output port="result" />

    <p:xslt>
        <p:input port="stylesheet">
            <p:inline>
                <xsl:stylesheet version="2.0">
                    <xsl:template match="/">
                        <xsl:copy-of select="." />
                        <xsl:result-document href="test1.xml">
                            <test1/>
                        </xsl:result-document>
                        <xsl:result-document href="test2.xml">
                            <test2/>
                        </xsl:result-document>
                    </xsl:template>
                </xsl:stylesheet>
            </p:inline>
        </p:input>
    </p:xslt>
</p:declare-step>
Received on Tuesday, 3 March 2009 18:46:46 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 March 2009 18:46:46 GMT