You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Fe...@thomson.com on 2006/03/08 12:08:53 UTC

xpatch fails (removal)

I am trying to get rid of the home directory mapping in the sitemap.
I've tried the following patch, but all I get is a NullPointerException


<xmap 
    xpath="/sitemap/pipelines/pipeline/match[@pattern='~*/**']"
    remove="current()"
/>

Thanks

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: xpatch fails (removal)

Posted by Brian Vargas <ar...@procrastinators.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Fernando,

I'm pretty sure that's because the remove attribute is executed external
to any context that may be provided by the xpath attribute.  Thus,
current() is not defined, and you get a NullPointerException.

If you replicate the xpath attribute value in the remove attribute, it
should work as you expect.

Brian

Fernando.Matomira@thomson.com wrote:
> I am trying to get rid of the home directory mapping in the sitemap.
> I've tried the following patch, but all I get is a NullPointerException
> 
> 
> <xmap 
>     xpath="/sitemap/pipelines/pipeline/match[@pattern='~*/**']"
>     remove="current()"
> />
> 
> Thanks
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (MingW32)
Comment: What is this? http://pgp.ardvaark.net

iD8DBQFEHvcL3YdPnMKx1eMRAzugAKCDyJSzcN/6BH7nRtY2PQgIQhZnfACeJbx9
QGEWAjJY76CiH6hKPJCrKdY=
=TWB9
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org