473,785 Members | 2,801 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Xalan-J cannot run extension function examples

I have tried to run the extension function/element examples provided
with the Xalan-J download. I believe that my classpath is correct,
and that my versions are up-to-date. However, I can't get past the
following error. Any help, please?
=============== =============== =============== =============== ===============

C:\xalan>test

C:\xalan>REM @echo off

C:\xalan>set XALANPATH=C:\xa lan\xalan-j_2_6_0

C:\xalan>set CLASSPATH=C:\xa lan\xalan-j_2_6_0\bin\xal an.jar

C:\xalan>set CLASSPATH=C:\xa lan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6
_0\bin\xercesIm pl.jar

C:\xalan>rem ~~~~~~ EXTENSIONS ~~~~~

C:\xalan>set ClassPath=C:\xa lan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6
_0\bin\xercesIm pl.jar;C:\xalan \xalan-j_2_6_0\bin\xml-apis.jar

C:\xalan>set ClassPath=C:\xa lan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6
_0\bin\xercesIm pl.jar;C:\xalan \xalan-j_2_6_0\bin\xml-apis.jar;C:\xal an\xalan-j_2
_6_0\bin\bsf.ja r

C:\xalan>set ClassPath=C:\xa lan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6
_0\bin\xercesIm pl.jar;C:\xalan \xalan-j_2_6_0\bin\xml-apis.jar;C:\xal an\xalan-j_2
_6_0\bin\bsf.ja r;C:\xalan\xala n-j_2_6_0\rhino\j s.jar

C:\xalan>echo C:\xalan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6_0\bin\xe
rcesImpl.jar;C: \xalan\xalan-j_2_6_0\bin\xml-apis.jar;C:\xal an\xalan-j_2_6_0\bin\
bsf.jar;C:\xala n\xalan-j_2_6_0\rhino\j s.jar
C:\xalan\xalan-j_2_6_0\bin\xal an.jar;C:\xalan \xalan-j_2_6_0\bin\xer cesImpl.jar;C
:\xalan\xalan-j_2_6_0\bin\xml-apis.jar;C:\xal an\xalan-j_2_6_0\bin\bsf .jar;C:\xal
an\xalan-j_2_6_0\rhino\j s.jar

C:\xalan>java -version
java version "1.4.2_03"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_03-b02)
Java HotSpot(TM) Client VM (build 1.4.2_03-b02, mixed mode)

C:\xalan>set SAMPLES=C:\xala n\xalan-j_2_6_0\samples \extensions

C:\xalan>set tstXML=C:\xalan \xalan-j_2_6_0\samples \extensions\2-basicJscript.xm l
C:\xalan>set tstXSL=C:\xalan \xalan-j_2_6_0\samples \extensions\2-basicJscript.xs l
C:\xalan>java org.apache.xala n.xslt.Process -IN
C:\xalan\xalan-j_2_6_0\samples \e
xtensions\2-basicJscript.xm l -XSL
C:\xalan\xalan-j_2_6_0\samples \extensions\2-ba
sicJscript.xsl -OUT test_out.txt
java.lang.refle ct.InvocationTa rgetException
at sun.reflect.Nat iveMethodAccess orImpl.invoke0( Native Method)
at sun.reflect.Nat iveMethodAccess orImpl.invoke(N ativeMethodAcce ssorImpl.
java:39)
at sun.reflect.Del egatingMethodAc cessorImpl.invo ke(DelegatingMe thodAcces
sorImpl.java:25 )
at java.lang.refle ct.Method.invok e(Method.java:3 24)
at org.apache.xala n.extensions.Ex tensionHandlerG eneral.<init>(E xtensionH
andlerGeneral.j ava:293)
at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance0(Nativ e
Method)

at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance(Native Construct
orAccessorImpl. java:39)
at sun.reflect.Del egatingConstruc torAccessorImpl .newInstance(De legatingC
onstructorAcces sorImpl.java:27 )
at java.lang.refle ct.Constructor. newInstance(Con structor.java:2 74)
at org.apache.xala n.extensions.Ex tensionNamespac eSupport.launch (Extensio
nNamespaceSuppo rt.java:74)
at org.apache.xala n.extensions.Ex tensionsTable.< init>(Extension sTable.ja
va:118)
at org.apache.xala n.transformer.T ransformerImpl. setExtensionsTa ble(Trans
formerImpl.java :437)
at org.apache.xala n.transformer.T ransformerImpl. transformNode(T ransforme
rImpl.java:1169 )
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:668)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1129)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1107)
at org.apache.xala n.xslt.Process. main(Process.ja va:1041)
Caused by: com.ibm.bsf.BSF Exception: JavaScript Error: Internal Error:
java.lang
..IllegalArgume ntException: Line number can not be negative:-1
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.handleError( JavaScrip
tEngine.java:18 2)
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.eval(JavaScr iptEngine
..java:87)
at com.ibm.bsf.uti l.BSFEngineImpl .exec(BSFEngine Impl.java:106)
... 17 more
javax.xml.trans form.Transforme rException:
java.lang.refle ct.InvocationTa rgetExce
ption
at org.apache.xala n.extensions.Ex tensionNamespac eSupport.launch (Extensio
nNamespaceSuppo rt.java:80)
at org.apache.xala n.extensions.Ex tensionsTable.< init>(Extension sTable.ja
va:118)
at org.apache.xala n.transformer.T ransformerImpl. setExtensionsTa ble(Trans
formerImpl.java :437)
at org.apache.xala n.transformer.T ransformerImpl. transformNode(T ransforme
rImpl.java:1169 )
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:668)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1129)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1107)
at org.apache.xala n.xslt.Process. main(Process.ja va:1041)
Caused by: java.lang.refle ct.InvocationTa rgetException
at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance0(Nativ e
Method)

at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance(Native Construct
orAccessorImpl. java:39)
at sun.reflect.Del egatingConstruc torAccessorImpl .newInstance(De legatingC
onstructorAcces sorImpl.java:27 )
at java.lang.refle ct.Constructor. newInstance(Con structor.java:2 74)
at org.apache.xala n.extensions.Ex tensionNamespac eSupport.launch (Extensio
nNamespaceSuppo rt.java:74)
... 7 more
Caused by: javax.xml.trans form.Transforme rException: Could not compile
extension

at org.apache.xala n.extensions.Ex tensionHandlerG eneral.<init>(E xtensionH
andlerGeneral.j ava:300)
... 12 more
Caused by: java.lang.refle ct.InvocationTa rgetException
at sun.reflect.Nat iveMethodAccess orImpl.invoke0( Native Method)
at sun.reflect.Nat iveMethodAccess orImpl.invoke(N ativeMethodAcce ssorImpl.
java:39)
at sun.reflect.Del egatingMethodAc cessorImpl.invo ke(DelegatingMe thodAcces
sorImpl.java:25 )
at java.lang.refle ct.Method.invok e(Method.java:3 24)
at org.apache.xala n.extensions.Ex tensionHandlerG eneral.<init>(E xtensionH
andlerGeneral.j ava:293)
... 12 more
Caused by: com.ibm.bsf.BSF Exception: JavaScript Error: Internal Error:
java.lang
..IllegalArgume ntException: Line number can not be negative:-1
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.handleError( JavaScrip
tEngine.java:18 2)
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.eval(JavaScr iptEngine
..java:87)
at com.ibm.bsf.uti l.BSFEngineImpl .exec(BSFEngine Impl.java:106)
... 17 more
---------
java.lang.refle ct.InvocationTa rgetException
at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance0(Nativ e
Method)

at sun.reflect.Nat iveConstructorA ccessorImpl.new Instance(Native Construct
orAccessorImpl. java:39)
at sun.reflect.Del egatingConstruc torAccessorImpl .newInstance(De legatingC
onstructorAcces sorImpl.java:27 )
at java.lang.refle ct.Constructor. newInstance(Con structor.java:2 74)
at org.apache.xala n.extensions.Ex tensionNamespac eSupport.launch (Extensio
nNamespaceSuppo rt.java:74)
at org.apache.xala n.extensions.Ex tensionsTable.< init>(Extension sTable.ja
va:118)
at org.apache.xala n.transformer.T ransformerImpl. setExtensionsTa ble(Trans
formerImpl.java :437)
at org.apache.xala n.transformer.T ransformerImpl. transformNode(T ransforme
rImpl.java:1169 )
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:668)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1129)
at org.apache.xala n.transformer.T ransformerImpl. transform(Trans formerImp
l.java:1107)
at org.apache.xala n.xslt.Process. main(Process.ja va:1041)
Caused by: javax.xml.trans form.Transforme rException: Could not compile
extension

at org.apache.xala n.extensions.Ex tensionHandlerG eneral.<init>(E xtensionH
andlerGeneral.j ava:300)
... 12 more
Caused by: java.lang.refle ct.InvocationTa rgetException
at sun.reflect.Nat iveMethodAccess orImpl.invoke0( Native Method)
at sun.reflect.Nat iveMethodAccess orImpl.invoke(N ativeMethodAcce ssorImpl.
java:39)
at sun.reflect.Del egatingMethodAc cessorImpl.invo ke(DelegatingMe thodAcces
sorImpl.java:25 )
at java.lang.refle ct.Method.invok e(Method.java:3 24)
at org.apache.xala n.extensions.Ex tensionHandlerG eneral.<init>(E xtensionH
andlerGeneral.j ava:293)
... 12 more
Caused by: com.ibm.bsf.BSF Exception: JavaScript Error: Internal Error:
java.lang
..IllegalArgume ntException: Line number can not be negative:-1
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.handleError( JavaScrip
tEngine.java:18 2)
at com.ibm.bsf.eng ines.javascript .JavaScriptEngi ne.eval(JavaScr iptEngine
..java:87)
at com.ibm.bsf.uti l.BSFEngineImpl .exec(BSFEngine Impl.java:106)
... 17 more

file:///C:/xalan/xalan-j_2_6_0/samples/extensions/2-basicJscript.xs l;
Line #33;
Column #42; XSLT Error (javax.xml.tran sform.Transform erException):
java.lang.Nul
lPointerExcepti on

C:\xalan>
Jul 20 '05 #1
1 2308
Make sure you're using 1.4.2
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
4031
by: al dav | last post by:
Hi all ok i am not a java programmer I am a sys-admin, my users want xalan and have already got j2sdk_1.4.2 so i have downloaded it and set the CLASS_PATH export CLASS_PATH=/usr/local/java/xalan-j_2_5_2/bin/xalan.jar:/usr/local/java/xalan -j_2_5_2/bin/xml-apis.jar:/usr/local/java/xalan-j_2_5_2/bin/xercesImpl.jar:/
1
7359
by: Bekkali Hicham | last post by:
hi, i have already used xalan several times with success, but i have a error message that i don't understand, thanks for your help (Emplacement inconnu de l'erreur) Erreur XSLT (javax.xml.transform.TransformerConfigurationException): javax.xml.transform.TransformerException: java.io.UTFData FormatException: Invalid byte 2 of 3-byte UTF-8 sequence. thanks
0
1492
by: Guillaume Jeudy | last post by:
Hi, I'm trying to serialize a DOM constructed from the following URL which is subject to change very frequently: http://www.bbc.co.uk/syndication/feeds/news/ukfs_news/world/asia-pacific/rss091.xml I sometimes receive this error: java.lang.NullPointerException:
7
2146
by: Ganesh Gella | last post by:
Hi All, I am planning to use Xalan to transform XML data by applying xls stylesheets. Here tricky part is, Xalan provides several C++ APIs, which are very much useful if our requirement is just inputting a file and getting a file. Or giving a xerces dom and get a new xerces dom. I would like to know whether any of you tried with their own custom
2
2111
by: Dr. Roger Wießner | last post by:
Hello! I am a newbie to XSLT and need a freeware/GNU Tool to get experience with this new topic. Which one is a good XSLT? Xalan or Saxon, or which one else? Thank you a lot!
5
1782
by: John | last post by:
I'm trying to generate HTML using a SAX TransformHandler. The problem I'm having is related to the xalan transformer using the shorthand notation when it writes out an empty textarea tag. My code works fine when xalan.jar is not in my classpath. But when xalan.jar is in the classpath, the generated html incorrectly uses the shorthand notation for writing out an empty textarea tag. Correct output: C:\test>java Test
0
1200
by: terry.jeske | last post by:
Hello, I am trying to upgrade an application that was previously running on Xalan 1.4.2, to 2.7.0. I have worked out the build issues and now the application compiles with the new xalan and xerces. However, at runtime I get the following error when I try to do a transform: (Location of error unknown)org.xml.sax.SAXException: Can not resolve
1
1656
by: redcic | last post by:
Hi, Does anyone know which version of Java Virtual Machine I need to run Xalan 2.7.0. I've got difficulties with Java 1.1.8. Thanks, Cédric
3
1214
by: Anonymous | last post by:
Has anyone managed to build Xalan v 1.10 using VS 2005? If the VS 7 project is converted to VS 8.0., it generates *TONS* of errors - anyone managed to build this yet?
3
2019
by: awebguynow | last post by:
What are the rules for classpath, when using Xalan on the command line? I'm using java J2SE 1.6.0 but haven't used Xalan for a while and ran into all kinds of troubles today. Of course, I went to the Apache site and got the binary jar's, since it looks like Sun stopped including it. I'd also like some advice on using compiling servlets that will use
0
9645
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10324
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9949
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8971
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6739
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5380
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4050
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3645
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2879
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.