For a single subelement condition, you can locate the subelement and then
locate it's parent. But this is probably not generalizable with the
current XPointer syntax.
This is one of the difficult design choices faced by the XPointer
designers: by making the language completely declarative there will be many
things that can't be specified (or can't be specified in an obvious or
efficient way) but making the language procedural significantly complicates
the language and its implementation. Putting in a hook where arbitrary
functions can go avoids the design problem but does not help with
interchange very much. One obvious problem would be how to indicate the
language that the function is in? HyTime solves this by requiring that all
non-HyTime queries be associated with a declared notation--XPointer would
have to provide the equivalent, presumably through a PI of some sort (the
alternative would be to specify the full external ID of the query
definition document--a notation declaration is, after all, nothing more
than indirection to document that defines the notation's rules).
Cheers,
E.
-- <Address HyTime=bibloc> W. Eliot Kimber, Senior Consulting SGML Engineer ISOGEN International Corp. 2200 N. Lamar St., Suite 230, Dallas, TX 75202. 214.953.0004 www.isogen.com </Address>