- From: Chelsea Valentine <chelseavalentine@gmail.com>
- Date: Thu, 15 Apr 2010 10:45:33 -0500
- To: xproc-dev@w3.org
Hi all,
I am wanting to pass in a parameter and file path/name. The parameter
passed in would identify the file type and a choose statement would
select the correct <when> path based on that parameter value.
What I don't know is how to catch a parameter when it is passed in.
Any help is greatly appreciated.
The basic structure would be:
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc" name="myPipeline"
version="1.0">
<p:input port="source"/>
<p:output port="result"/>
<p:choose name="convertToPrepModel">
<p:when test="[test parameter passed in]">
<!-- subpipeline //-->
<p:xslt name="convertToPrepModelTransformation">
<p:input port="source"/>
<p:input port="stylesheet">
<p:document href="stylesheet.xsl"/>
</p:input>
<p:input port="parameters" sequence="true">
<p:empty/>
</p:input>
</p:xslt>
</p:when>
<p:otherwise>
<p:xslt name="convertToPrepModelTransformation">
<p:input port="source"/>
<p:input port="stylesheet">
<p:document href="stylesheet.xsl"/>
</p:input>
<p:input port="parameters" sequence="true">
<p:empty/>
</p:input>
</p:xslt>
</p:otherwise>
</p:choose>
....
</p:declare-step>
Received on Friday, 16 April 2010 07:28:31 UTC