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

Use Case 5.12 Pipeline

From: Alex Milowski <alex@milowski.com>
Date: Tue, 8 May 2012 12:01:49 -0700
Message-ID: <CABp3FNKog3wUZOg8bRss7kDiLmxPqEz-8+gcR3LCHWHAUArjjw@mail.gmail.com>
To: XProc WG <public-xml-processing-model-wg@w3.org>
I'm assuming the "result" is the result of the transformation. As
such, I don't need to go the persistence service to get that.   The
p:store could be another p:http-request or ml:insert-document, etc. in
a more complicated system.

<?xml version="1.0" encoding="UTF-8"?>
<p:declare-step xmlns:p="http://www.w3.org/ns/xproc"
   xmlns:c="http://www.w3.org/ns/xproc-step" version="1.0">
   <p:option name="href" required="true"/>
   <p:option name="output-href" required="true"/>
   <p:output port="result">
      <p:pipe step="transform" port="result"/>
   </p:output>
   <p:template>
      <p:with-param name="url" select="$href"/>
      <p:input>
         <p:inline>
            <c:request method="GET" href="{$url}"/>
         </p:inline>
      </p:input>
   </p:template>
   <p:http-request/>
   <p:xslt name="transform">
      <p:input port="stylesheet">
         <p:document href="transform.xsl"/>
      </p:input>
   </p:xslt>
   <p:store>
      <p:with-option name="href" select="$output-href"/>
   </p:store>
</p:declare-step>

-- 
--Alex Milowski
"The excellence of grammar as a guide is proportional to the paucity of the
inflexions, i.e. to the degree of analysis effected by the language
considered."

Bertrand Russell in a footnote of Principles of Mathematics
Received on Tuesday, 8 May 2012 19:02:21 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 May 2012 19:02:22 GMT