- From: Innovimax SARL <innovimax@gmail.com>
- Date: Tue, 7 Aug 2007 08:46:11 +0200
- To: "Norman Walsh" <ndw@nwalsh.com>
- Cc: public-xml-processing-model-wg@w3.org
On 8/7/07, Norman Walsh <ndw@nwalsh.com> wrote: > / Innovimax SARL <innovimax@gmail.com> was heard to say: > | On 8/6/07, Norman Walsh <ndw@nwalsh.com> wrote: > |> Do we expect the following pipeline to work? > |> > |> <p:pipeline xmlns:p="..."> > |> <p:option name="delete" value="html:div" > |> xmlns:html="http://www.w3.org/1999/xhtml"/> > | > | Here there is no need to declare html since value is just a string > > See 5.7.3. Ok fair enough > > |> <p:delete> > |> <p:input port="source"> > |> <p:inline> > |> <html xmlns="http://www.w3.org/1999/xhtml"> > |> <head>...</head> > |> <body> > |> <h1>Delete My Divs</h1> > |> <div> > |> ... > |> </div> > |> </body> > |> </p:inline> > |> </p:input> > |> > |> <p:option name="match" select="$delete"/> > | > | Here the inscope namespace do not contains html so it is a error > > Well, see 2.8.1. > > The question is, do we *want* this to work. Should the namespace > binding associated with the option $delete be available on the > option named "match" because we refer to the $delete option? Tricky question. Thanks now I see your point > > | --> I have only one problem : WHICH ERROR ? > | > |> </p:delete> > |> </p:pipeline> > |> > |> Where "work" means that the pipeline runs and produces: > |> > |> <html xmlns="http://www.w3.org/1999/xhtml"> > |> <head>...</head> > |> <body> > |> <h1>Delete My Divs</h1> > |> </body> > | > | No (see above) > | > |> > |> Suppose local.xml contains: > |> > |> <commands> > |> <delete xmlns:h="http://www.w3.org/1999/xhtml" > |> match="h:div"/> > |> </commands> > |> > |> Do we expect this to work? > |> > |> <p:pipeline xmlns:p="..."> > |> <p:load name="load-commands" href="local.xml"/> > |> > |> <p:delete> > |> <p:input port="source"> > |> <p:inline> > |> <html xmlns="http://www.w3.org/1999/xhtml"> > |> <head>...</head> > |> <body> > |> <h1>Delete My Divs</h1> > |> <div> > |> ... > |> </div> > |> </body> > |> </p:inline> > |> </p:input> > |> > |> <p:option name="match" select="/commands/delete/@match"> > |> <p:pipe step="load-commands" port="result"/> > |> </p:option> > |> </p:delete> > |> </p:pipeline> > | > | This one is trickier : it depends if we adopt the strategy to augment > | the available namespaces with the one in the context of the XPath > | expression > > I think we want to be consistent. Either both should be an error, > or neither. > > The simplest thing to do is make it an error, but doing so makes the > "read from file" case not just an error sometimes, but sometimes it > can give the wrong result. Possible, but by letting it be computed in a "implementation defined" fashion, it could also gives wrong results, couldn't it ? Mohamed -- Innovimax SARL Consulting, Training & XML Development 9, impasse des Orteaux 75020 Paris Tel : +33 9 52 475787 Fax : +33 1 4356 1746 http://www.innovimax.fr RCS Paris 488.018.631 SARL au capital de 10.000 €
Received on Tuesday, 7 August 2007 06:46:13 UTC