Well, I run into other problems then:

Error  : XS0011: Duplicate port name: source
Error  : XS0011: Duplicate port name: parameters
Error  : XS0011: Duplicate port name: result

and I need to be able to declare the source port so I can bind it to my source file.

I'll send a mail to Norman Walsh.

Incidentally, the problem forced me to find a workaround which I think is better than my original plan. Basically, I'm trying to drive my whole import/export process from a simple XML specification file like this:

<pipeline-spec>
  <import>
    <source-folder>/some/folder/</source-folder>
    <source-format>rng</source-format>
    <output-folder>ebk</output-folder>
    <file-stem>syndication</file-stem>
    <params>
      <parent>book</parent>
      <title></title>
    </params>
  </import>
</pipeline-spec>

Instead of individually passing the parameters to the parameter port, what I do now is run a little transformation that picks out all the children of <params> and converts them into a c:param-set, which I then pass in to the parameter port:

  <p:xslt name="get-params">
    <p:input port="stylesheet">
        <p:document href="easybook-xsl:ebp-xpp.xsl"/>
    </p:input>
  </p:xslt>

....

          <eb:rng-ebk>
            <p:input port="parameters">
              <p:pipe step="get-params" port="result"/>
            </p:input>
          </eb:rng-ebk>

This solution is completely generic: I don't need to know the names of the parameters! The more I use xproc, the better I like it...

Thanks very much for your help, Vojtech

Kevin
Toman_Vojtech@emc.com wrote:
It looks like a bug to me. Could you try to use p:pipeline instead of p:declare-step for the top-level pipeline? I remember that in the older versions of the spec, the default binding to the pipeline's primary parameter input port happened only when p:pipeline was used. Perhaps Calabash does not handle this properly with p:declare-step?
 
Regards,
Vojtech


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

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