W3C home > Mailing lists > Public > public-xml-processing-model-comments@w3.org > October 2007

Re: injecting options and parameters into XProc

From: Norman Walsh <ndw@nwalsh.com>
Date: Wed, 10 Oct 2007 09:57:10 -0400
To: public-xml-processing-model-comments@w3.org
Message-ID: <m2prznrs21.fsf@nwalsh.com>
/ Vasil Rangelov <boen.robot@gmail.com> was heard to say:
| XProc doesn't allow that, but it does allow something else, which I
| think is more logical.
|
| You can define a *default* value for an option at the top of a
| pipeline. If a step has the same option, it will use that value.

Not automatically.

| And
| when the pipeline is invoked, it can override the value you've
| specified at the top of the pipeline.
|
| Example:
| <p:pipeline xmlns:p="http://www.w3.org/ns/xproc">
|   <p:option name="allow-version-mismatch" value="yes"/>
|   <p:option name="template-name" value="start"/>
|   <p:xslt2>
|     <p:input port="stylesheet">
|       <p:document href="stylesheet1.xsl"/>
|     </p:input>
      <p:option name="allow-version-mismatch" select="$allow-version-mismatch"/>
|   </p:xslt>
|   <p:xslt2>
|     <p:input port="stylesheet">
|       <p:document href="stylesheet2.xsl"/>
|     </p:input>
      <p:option name="allow-version-mismatch" select="$allow-version-mismatch"/>
|   </p:xslt>
|   <p:xslt2>
|     <p:option name="template-name" value="finish"/>
|     <p:input port="stylesheet">
|       <p:document href="stylesheet2.xsl"/>
|     </p:input>
      <p:option name="allow-version-mismatch" select="$allow-version-mismatch"/>
|   </p:xslt>
| </p:pipeline>

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <ndw@nwalsh.com> | Simplicity is always a virtue.--Edward
http://nwalsh.com/            | Abbey

Received on Wednesday, 10 October 2007 13:57:21 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:21:42 GMT