Short form of p:base-uri() and p:resolve-uri()

Just a question about p:base-uri() and p:resolve-uri() functions. Do we
really want the XProc implementations to support the no-argument version
p:base-uri() and p:resolve-uri(relative)? I mean, they can be always
expressed using the 'longer form':

p:base-uri() -> p:base-uri(.) 
p:resolve-uri(relative) -> p:resolve-uri(relative, p:base-uri(.))

I know we have two versions because XPath 2.0 has them, but at the same
time, we have introduced these new functions to provide functionality
that would otherwise be missing in XPath 1.0 based implementations. To
me, the 'short form' is just a convenience API for the user.

Actually, the main reason why I am asking is more prosaic: I am just
implementing these two functions using Java XPath API and it seems like
there is no way you can get a reference to the current context node in
the implementation of XPathFunction interface. Although I agree this is
more an implementation problem than a problem in the spec...

Regards,
Vojtech

Received on Friday, 25 April 2008 12:35:15 UTC