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

RE: Dynamically setting the text of an added element in a pipeline . . ?

From: <vojtech.toman@emc.com>
Date: Thu, 10 Mar 2011 04:54:42 -0500
To: <xproc-dev@w3.org>
Message-ID: <3799D0FD120AD940B731A37E36DAF3FE334C19B8A3@MX20A.corp.emc.com>
If I understood your example correctly, you want to iterate to iterate over a sequence of documents, and insert the "field" element in each of them. In your original source, the "source" primary input port if p:identity was automatically bound to the "current" port of p:for-each, because p:insert was the first step of the sub-pipeline. However, with the addition of p:string-replace/p:template, p:identity needs to use an explicit binding to the "current" port of p:for-each otherwise it would use the result of the p:string-replace/p:template as the source.


Vojtech Toman
Consultant Software Engineer
EMC | Information Intelligence Group

From: Alex Muir [mailto:alex.g.muir@gmail.com]
Sent: Thursday, March 10, 2011 10:48 AM
To: Toman, Vojtech
Cc: xproc-dev@w3.org
Subject: Re: Dynamically setting the text of an added element in a pipeline . . ?


Just a general question. When UploadInGroups, the name of the for-loop is the source pipe for the p:insert within the for-loop what is this doing?

       <p:input port="source">
        <p:pipe step=" UploadInGroups" port="current"/>

<p:for-each name="UploadInGroups">
  <p:template name="create-field">
    <p:input port="template">
        <field name="iterationCount">$pos</field>
    <p:with-param name="pos" select="p:iteration-position()"/>
  <p:insert position="last-child" match="/add/doc" name="insertCounter">
      <p:input port="source">
        <p:pipe step=" UploadInGroups" port="current"/>
      <p:input port="insertion">
        <p:pipe step="create-field" port="result"/>
    . . .

Received on Thursday, 10 March 2011 09:56:18 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:03:08 UTC