W3C home > Mailing lists > Public > xproc-dev@w3.org > June 2009

Re: Recommendation needed: how to provide a user-defined step (pipeline) with a subset of information

From: Norman Walsh <ndw@nwalsh.com>
Date: Sun, 14 Jun 2009 10:51:48 -0400
To: XProc Dev <xproc-dev@w3.org>
Message-ID: <m21vpmlvgb.fsf@nwalsh.com>
"Costello, Roger L." <costello@mitre.org> writes:
> I don't want to send all this to my user-defined step; I only want
> to send Age and State.

If you think that you might eventually want to extract more information,
I'd be tempted to send an XML document that contains just he extracted
pieces you need:

  <source-data>
    <state>MA</state>
    <age>41</age>
  </source-data>

and extract state and age from that inside your step. Then you can write
another step that transforms applications into <source-data> documents.

I might also use options.

I don't think I'd have made an input for state and an input for age, at
least that wouldn't have been my first approach.

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <ndw@nwalsh.com> | In real life, unlike in Shakespeare,
http://nwalsh.com/            | the sweetness of the rose depends upon
                              | the name it bears. Things are not only
                              | what they are. They are, in very
                              | important respects, what they seem to
                              | be.--Hubert H. Humphrey

Received on Sunday, 14 June 2009 14:52:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 14 June 2009 14:52:28 GMT