[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Not able to render image generated by Java Extension

Subject: Not able to render image generated by Java Extension Function when called from XSL
From: "Charanpreet Arora" <send2charan@xxxxxxxxx>
Date: Tue, 8 Jan 2008 11:00:38 -0800
 Not able to render image generated by Java Extension
Hi,

I'm using createImage() method of transformer.util.DrawSignature class
in my application to generate an image in a temporary location.
Signature of method is as follows:

public static void createImage(String signature) {
......
}

I need to display this image on a pdf file generated using xsl
stylesheets. Below is the snapshot of the stylesheet. It calls
createImage method which generates image in temp location; the image
is picked up from the temp location and displayed using
<fo:external-graphic>

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:fo="http://www.w3.org/1999/XSL/Format"
    version="1.0"
    xmlns:drawSign="transformer.util.DrawSignature">

<xsl:template name="signature">
        <xsl:value-of select="drawSign:createImage(//sign)"/>
        <fo:block>
            <fo:external-graphic src="out/sign.gif"
content-height="0.7in" vertical-align="middle"/>
        </fo:block>

    </xsl:template>

</xsl:stylesheet>

Heres the problem description:

When I run my transformer through the above stylesheets, it throws the
following error:

(Location of error unknown)java.lang.NoSuchMethodException: For
extension function, could not find method
org.apache.xml.utils.NodeVector.createImage([ExpressionContext,] ).

I'm really not sure why it is looking createImage not in the correct
path even though the jar containing DrawSignature class  is properly
set in the classpath. Is my xsl incorrect or there is some issue with
the JVM not able to locate jar? please note that when I run the
drawSignature program standalone, image is generated in the desired
location but I'm not able to pick the same and render it through
stylesheets. Any help in this regard is greatly appreciated.

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.