No, that doesn't seem to work.

The main pipeline has a primary parameter input port:

<p:declare-step ...[ns-declarations]... name="import">
...
      <p:input port="parameters" kind="parameter"/>
...


and so does the called step eb:rng-ebk:

  <p:declare-step type="eb:rng-ebk">
        <p:input port="source"/>
        <p:input port="parameters" kind="parameter"/>
        <p:output port="result"/>

This works:

          <eb:rng-ebk>
            <p:input port="parameters">
              <p:inline>
                <c:param name="parent" value="book"/>
              </p:inline>
            </p:input>
          </eb:rng-ebk>

This doesn't:

          <eb:rng-ebk>
            <p:input port="parameters"/>
            <p:with-param name="parent" select="'book'">
              <p:empty/>
            </p:with-param>
          </eb:rng-ebk>

Explicitly connecting the port to the import/parameters port makes no difference, as expected.

Is this a bug in Calabash, perhaps?

Kevin

Toman_Vojtech@emc.com wrote:
Hi Kevin,
 
p:with-param should work. But it looks to me that you wan to use it in the step *declaration*, not in the step *invocation* (because of the kind="parameter" attributes on p:input)?
 
If you do something like this in your pipeline:
 
...
<eb:rng-ebk>
  <p:input port="parameters">
    <p:pipe step="..." port="..."/>
  <p:input>
  <p:with-param name="parent" select="'book'">
    <p:empty/>
  </p:with-param>
</eb:rng-ebk>
...
 
It should work. Note that you can omit the p:pipe binding for the parameter input port if the main pipeline has a primary parameter input port.
 
Regards,
Vojtech
 


From: xproc-dev-request@w3.org [mailto:xproc-dev-request@w3.org] On Behalf Of Kevin Flynn
Sent: Friday, July 03, 2009 8:03 AM
To: xproc-dev@w3.org
Subject: Difficulty overriding parameter values

In one of my pipelines, I want to override a parameter called "parent"  with a computed value, but can't seem to get it to work. I can override as follows:

<eb:rng-ebk>
 <p:input port="parameters" kind="parameter">
  <p:inline>
   <c:param value="parent" value="book"/>
  </p:inline>
 </p:input>
</eb:rng-ebk>

but then I can't set "value" using an Xpath expression. This, on the other hand simply doesn't work:

<eb:rng-ebk>
  <p:input port="parameters" kind="parameter"/>
  <p:with-param name="parent" select="'book'"/>
</eb:rng-ebk>

According to the following example in the xproc spec, the above should work, I believe:

http://www.w3.org/TR/xproc/#ex.parameter

Am I misunderstanding something? I think I may be. I also think that in the text following the above example, the words "before" and "after" may have got swapped: the text doesn't seem to match the example.

I am using calabash 0.9.10. eb:rng-ebk is a compound step that runs a chain of transformations, one of which takes "parent" as a parameter.

Regards,

Kevin Flynn