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

XSL Xalan extension problem

Subject: XSL Xalan extension problem
From: "PHDB _" <phdb2000@xxxxxxxxxxx>
Date: Tue, 18 May 2004 13:49:24 +0000
could not find method org.apache.xml.utils.nodevec
Hi,

I'm beginning with SXL extensions and I tried the example below but only got
XSLT Error (javax.xml.transform.TransformerException): java.lang.NoSuchMethodException: For extension function, could not find method org.apache.xml.utils.NodeVector.convertDate([ExpressionContext,] ).


I don't understand what it corresponds to or where I'm wrong.

Could somebody help me please ?
Many Thks,

-------------
Java class : Converter
-------------

package TestXalan;

public class Converter
{

 public Converter()
 {
 }

 public String convertDate(String aDate)
  {
     String aString ="";
     // (...)
     return aString;
  }
}

------------------
XLS sheet : ConvertCat002.xsl
-----------------

<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xalan="http://xml.apache.org/xalan" xmlns:my-class="java:TestXalan.Converter">
<xalan:component prefix="my-class" functions="convertDate">
<xalan:script lang="javaclass" src="xalan://TestXalan.Converter"/>
</xalan:component>
<xsl:output method="xml"/>
<xsl:template match="ReservationEffectiveDate|TicketingEffectiveDate|TravelEffectiveDate">
<xsl:variable name="date" select="."/>
<xsl:value-of select="my-class:convertDate($date)"/>
</xsl:template>
</xsl:stylesheet>


--------------
and I'm calling

@java -classpath C:/xerces-2_6_0/xercesImpl.jar;C:/jwsdp-1.3/jaxp/lib/endorsed/xalan.jar;lib/bsf.jar;lib/bsfengines.jar;classes org.apache.xalan.xslt.Process -in Cat002.xml -xsl ConvertCat002.xsl -out ConvertedCat002.xml

_________________________________________________________________
MSN Messenger http://g.msn.fr/FR1001/866 : dialoguez en direct et gratuitement avec vos amis !


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.