Brent,

I work with the xsltc team and just subscribed to this alias. I think 
the doc has a slight error in it. The following lines

>    xmlns:Java="http://xml.apache.org/xslt/Java";
>    xmlns:Java-system="http://xml.apache.org/xslt/Java/java.lang.System";>

should have lower-case "java" not "Java". 

Sorry. I know how frustrating these things can be. 

I was able to reproduce your problem, getting the "function not
available" error with the initial capital spelling, and 
got it to work with the lowercase spelling.

I'll see that the doc is fixed.

Tom

> Well - at least I'm not the only one with this problem.  Are there any
> Xalan developers on this list who can answer this question?  I did find the
> following on the Xalan-J website, although I still can't get it to make the
> call.  If this isn't supported, does anyone know any other way to make java
> calls in a stylesheet using a translet/xsltc with xalan or any other xsl
> transform package?
> 
> http://xml.apache.org/xalan-j/xsltc_constraints.html
>  -----
> At the time of writing, only static methods are supported. A call to a
> function whose namespace is either <http://xml.apache.org/xslt/Java or
> <http://xml.apache.org/xalan/xsltc/Java is resolved by loading the
> appropriate class and calling a static method that matches the signature of
> the function. The class can be specified as part of the namespace URI or as
> part of the function call as shown in the following example:
> 
> 
>   <xsl:stylesheet version="1.0"
>    xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
>    xmlns:Java="http://xml.apache.org/xslt/Java";
>    xmlns:Java-system="http://xml.apache.org/xslt/Java/java.lang.System";>
>    <xsl:template match="/">
>      <xsl:value-of select="Java:java.lang.System.currentTimeMillis()"/>
>      <xsl:value-of select="Java-system:currentTimeMillis()"/>
>   </xsl:template>
> </xsl:stylesheet>
>  -----
> 
> Thanks,
> 
> - Brent

-- 
 Tom Amiro -- SQA Engineer
 Sun XML Technology Development
 voice: 781-442-0589 Fax: 781-442-1437
 eMail: [EMAIL PROTECTED]

Reply via email to