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

a component with * inputs

From: Innovimax SARL <innovimax@gmail.com>
Date: Sun, 29 Jul 2007 19:22:37 +0200
Message-ID: <546c6c1c0707291022w311b377dg7e5592e3895ef5c7@mail.gmail.com>
To: "XProc WG" <public-xml-processing-model-wg@w3.org>


When I was re reading the answer of Norm to my demand for a
p:equal-sequence (which was do-it-with-for-each !), I suddently see
that we cannot do that efficiently in for-each
And moreover that's a task that is useful

I propose to add a p:pack (not so sure about the name)

<p:declare-step type="p:pack">
     <p:input port="*" sequence="yes"/>
     <p:output port="result" sequence="yes"/>
     <p:option name="wrapper" required="yes"/>

What it does is simple

It takes p sequence (seq_1,....seq_p) of respective length (len_1, ....len_p)

It outputs a sequence of length max(len_1, ...len_p)
and for each position of doc of the result sequence
we have
result_1 (wrap(seq_1(i), .....seq_p(i))

Where seq_k(i) is non empty if k <= len_k

I was thinking to give a special component that can distribute
multiple flows at the same time, but the fact is that we that
component and for-each, you can do it as efficiently

I ask it for beeing a required step (since it's not difficult to implement)

Innovimax SARL
Consulting, Training & XML Development
9, impasse des Orteaux
75020 Paris
Tel : +33 9 52 475787
Fax : +33 1 4356 1746
RCS Paris 488.018.631
SARL au capital de 10.000 
Received on Sunday, 29 July 2007 17:22:40 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:32:43 UTC