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

Re: A proposal to restructure our top-level syntax

From: Alex Milowski <alex@milowski.org>
Date: Fri, 7 Dec 2007 08:03:50 -0800
Message-ID: <28d56ece0712070803s1982c2eq8d65b7dbef2dae26@mail.gmail.com>
To: public-xml-processing-model-wg@w3.org

On 11/30/07, Henry S. Thompson <ht@inf.ed.ac.uk> wrote:
>
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Richard pointed out on yesterday's call that the type/name clash on
> p:pipeline arose, as have other issues, because of the schizophrenic
> nature of p:pipeline.  Bear with me, but that triggered a thought
> which I want to try to work through: we should use p:declare-step to
> declare all steps.  That is, not just spec-defined steps, and
> implementation-defined steps, but user-defined steps also.
> User-defined steps are the steps formerly known as named pipelines.
>
> Here's how this would look:
>
> 1) Add optional subpipeline content to p:declare-step -- if it's
>    present, it's the definition:
>
> <p:declare-step
>   type = QName>
>     (p:input |
>      p:output |
>      p:option)*
>      _subpipeline_
> </p:declare-step>

This means a pipeline can be declared within a pipeline without the need
of a pipeline library.  I like it!!!

>
> 2) Simplify p:pipeline-library:
>
> <p:pipeline-library
>   ignore-prefixes? = prefix list
>   xpath-version? = string>
>     (p:import |
>      p:declare-step)*
> </p:pipeline-library>

Then a library is a set of step declarations.  Again, I like it!

>
> 3) Simplify p:pipeline itself -- it's now _only_ used for running
>    stuff, and is always nameless:
>
> <p:pipeline
>   ignore-prefixes? = prefix list
>   xpath-version? = string>
>     (p:input |
>      p:output |
>      p:option |
>      p:import |
>      p:declare-step |
>      p:log |
>      p:serialization)*,
>     subpipeline
> </p:pipeline>
>

Good.

> (Not sure why p:log is there -- can/should be removed?)
>
> 4) Remove the requirement that p:pipeline has to declare its inputs
>    and outputs -- applying the compound step output defaulting rule is
>    not a problem anymore, since all _named_ pipelines are defined with
>    declare-step, where i/o has never been defaulted.

Good.

>
> 5) Change the definition of p:pipe so that 'step' is optional, and if
>    omitted means the lexically inclosing p:pipeline.

Optional but also good.

>
> I think this is actually a much cleaner design.  It puts all the load
> of defining typed steps on declare-step.  It will actually make moving
> - From user-defined to implementation-defined a very smooth transition
> - -- we could even say that the content of a p:declare-step is actually
> a fallback -- implementations can supply builtin-definitions if they
> have them.

I agree.  I'm all for this change.

-- 
--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 Friday, 7 December 2007 16:04:06 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:21:54 GMT