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

RE: Semantics of p:wrap

From: <Toman_Vojtech@emc.com>
Date: Fri, 17 Jul 2009 10:05:37 -0400
Message-ID: <6E216CCE0679B5489A61125D0EFEC78710367D9D@CORPUSMX10A.corp.emc.com>
To: <public-xml-processing-model-comments@w3.org>
Hi,

I think you are right and that I got it wrong when implementing it (and
creating the test). The change you are proposing definitely makes things
clearer.

Regards,
Vojtech

> The spec says:
> 
> ...[a] node that matches the specified match pattern is replaced with
> a new element node whose QName is the value specified in the wrapper
> option. The content of that new element is a copy of the original,
> matching node.
> 
> I don't think that the wrap process recurses into matched nodes. The
> spec is ambiguously worded, however, and I propose the following
> change to fix it:
> 
>   When the match pattern does not match the document node, each node
>   that matches the specified match pattern is replaced with a new
>   element node whose QName is the value specified in the wrapper
>   option. The content of that new element is a copy of the original,
>   matching node. The wrap step performs a "shallow" wrapping, it does
>   not process the content of a matching node for further matches.
> 
>                                         Be seeing you,
>                                           norm
> 
> -- 
> Norman Walsh <ndw@nwalsh.com> | The trip doesn't exist that 
> can set you
> http://nwalsh.com/            | beyond the reach of cravings, fits of
>                               | temper, or fears. If it did, the human
>                               | race would be off there in a body.--
>                               | Seneca
> 
Received on Friday, 17 July 2009 14:06:32 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 17 July 2009 14:06:32 GMT