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

RE: Names for p:* steps

From: <Toman_Vojtech@emc.com>
Date: Fri, 22 Aug 2008 10:27:00 -0400
Message-ID: <6E216CCE0679B5489A61125D0EFEC7870C4E71A3@CORPUSMX10A.corp.emc.com>
To: <public-xml-processing-model-wg@w3.org>

> Imagine that library.xpl contains:
>   <p:library ...>
>     <p:declare-step name="xinclude-and-xslt">...</p:declare-step>
>   </p:library>
> Consider the following imaginary command line syntax:
> $ calabash -isource=- -oresult=- -s xinclude-and-xslt library.xpl
> This tells the processor to load "library.xpl" and run the step named
> "xinclude-and-xslt". All straightforward.
> Now suppose I want to just run the "add-attribute" step. I could wrap
> it in a pipeline, put it in a library, give it a name, and run it. But
> since the library for the XProc builtin steps is always loaded (at
> least conceptually), why do I have to do that? Why can't I just say:
> $ calabash -isource=- -oresult=- -s add-attribute \
>           match=div attribute-name=foo attribute-value=bar
> I can't because the standard p:add-attribute step doesn't have a name.

Can't you do something like this on the command line:

$ calabash -isource=- -oresult=- -s p:add-attribute \
           -xmlns:p=http://www.w3.org/ns/xproc \
           match=div attribute-name=foo attribute-value=bar

You don't need to give the step a name in this case, and it is also more
consistent with the way you would invoke the step in an XProc pipeline.

The step names are "local" in nature - if you import a library in a
pipeline, the step names are invisible in the target context, so the
pipeline does not see the names of the imported steps, only their types.
So, in my opinion, I think that using step types instead of names on the
command line is more correct.

Received on Friday, 22 August 2008 14:27:55 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:41:40 UTC