RE: [xsl] question regarding setting anyURI from java

Subject: RE: [xsl] question regarding setting anyURI from java
From: Robby Pelssers <Robby.Pelssers@xxxxxxx>
Date: Wed, 6 Jul 2011 18:13:07 +0200
Hi Michael,

Thx for clarifying. All these differences don't make life easier ;-) Next time
I will address the correct mailing list.

Robby

-----Original Message-----
From: Michael Kay [mailto:mike@xxxxxxxxxxxx]
Sent: Wednesday, July 06, 2011 5:55 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re: [xsl] question regarding setting anyURI from java

On 06/07/2011 16:34, Robby Pelssers wrote:
> Hi Michael,
>
> Although the snippet was showing a xquery, the very question itself was not
so much xquery related.  I would rather say it was related to Xpath
functions.
>
> I could have asked the same question in another format and the answer would
have been the same:
>
> <xsl:param name="uri" as="xs:anyURI"/>
>
> <xsl:template match="/">
>    <xsl:copy-of select="doc($uri)/Content"/>
> </xsl:template>
>
>
Well, the answer wouldn't be the same. The mapping from Java classes to
XPath types depends on the API you are using. From your exception it
looked as if you were using the XQJ API, which defines one set of rules,
and is specific to XQuery. Java-based XSLT processors define their own
set of rules (and they are different for each processor.)

Michael Kay
Saxonica

Current Thread