Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XSLT
|
XSLT General questions and answers about XSLT. For issues strictly specific to the book XSLT 1.1 Programmers Reference, please post to that forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XSLT section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 25th, 2004, 10:24 AM
Authorized User
 
Join Date: Jan 2004
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts
Default binding java from xslt

In short, I am trying to get the pixel width of an image. I have located the java class ImageInfo. Its API is http://www.geocities.com/marcoschmid...ImageInfo.html. I am losing all my hair (and the entire weekend) trying to use its getWidth() method from my XSLT. I am using Xalan-J with the namespace xmlns:java="http://xml.apache.org/xalan/java". I am getting errors like

file:javatest.xsl; Line #13; Column #88; XSLT Error (javax.xml.transform.TransformerException): java.lang
.NoSuchMethodException: For extension function, could not find method static ImageInfo.setInput([ExpressionContext,] #STRING).

no matter what I try. I would be so thankful for some help.

 
Old January 28th, 2004, 03:34 PM
Authorized User
 
Join Date: Jan 2004
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Based on a fellow XMLer's suggestion, I recompiled the class as a package and made a wrapper with a public static method, then it worked like all the examples you find on the web.

 
Old February 19th, 2004, 11:53 AM
Registered User
 
Join Date: Feb 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Could you be more specific about how you compiled the class as a package and made a wrapper?






Similar Threads
Thread Thread Starter Forum Replies Last Post
Java XSLT technologies ojasrege Java Basics 1 November 8th, 2007 01:17 AM
Using XSLT and JAVA trinkets XSLT 4 April 4th, 2007 02:13 PM
XSLT and JAVA bonekrusher XSLT 3 August 9th, 2006 07:38 PM
XSLT with Java Hind XSLT 1 May 24th, 2006 04:18 AM
Java & XSLT safin XSLT 0 September 8th, 2005 01:11 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.