Reputation: 27
I am debugging a XSLT and seeing the below error
<xsl:function name="this:sendquotedvalue" as="xs:string">
calling using the below lines
<xsl:value-of select="this:sendquotedvalue($emptyString)"/>
error i am getting is
The URI urn:this-stylesheet does not identify an external Java class
also have urn as below
xmlns:this="urn:this-stylesheet"
Any suggestion
-Prasanna.K
Upvotes: 0
Views: 379
Reputation: 163262
I suspect that your stylesheet specifies version="2.0" (or higher), but you are running it under an XSLT 1.0 processor.
A 1.0 processor is required to ignore declarations like xsl:function
if the stylesheet version is greater than 1.0 (this is called "forwards compatibility mode"). So the xsl:function
doesn't exist, which makes the attempt to call this function an error. For a 1.0 Java processor, there are only two kinds of functions that it knows about: built in core functions (in no namespace), and external Java functions. It's ruled out the first category because there's a namespace, and now it's telling you that it can't be an external Java function either, because the namespace doesn't map to any external Java class.
Note that specifying version="2.0" in a stylesheet doesn't magically give you an XSLT 2.0 processor; the rules for loading an XSLT processor (such as the JAXP factory rules) don't take the stylesheet version into account.
Upvotes: 1