wood burning stoves 2.0*
The moose likes Web Services and the fly likes Can't find a JAR for XML Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Can Watch "Can New topic
Author

Can't find a JAR for XML

Tommy Stanwalski
Greenhorn

Joined: Dec 24, 2004
Posts: 2
I am trying to use the *.jar files for XML. However, I can not find the one that contains the DOMImplementationLS object.

I am getting a ClassNotFoundError. Can anyone let tell me which jar file it is in?

Thank you
Tom
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12823
    
    5
Which version of Java do you have>? Which XML implementation are you trying to use?
Java 1.4 has a XML toolkit built in - it includes the org.w3c.dom.DOMImplementation interface.
Bill
Tommy Stanwalski
Greenhorn

Joined: Dec 24, 2004
Posts: 2
Thanks for replying so quickly.

I am not sure which version of J2SDK is on the server. I know it can't handle xml so its probably 1.2 or around there. As for which version of XML, again I am uncertain. I did not write the piece which needs the class, it is a black box api. All I know is that I get an error message on the server but not on my work station and my work station is running j2sdk1.4.1. This is the exception:

java.lang.NoClassDefFoundError: org/w3c/dom/ls/DOMImplementationLS
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:509)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1631)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:926)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1360)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1243)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:322)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:509)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1631)
at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:926)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1360)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1243)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:322)
at org.apache.xerces.dom.DocumentImpl.getImplementation(Unknown Source)
at org.apache.xerces.dom.CoreDocumentImpl.importNode(Unknown Source)
at org.apache.xerces.dom.CoreDocumentImpl.importNode(Unknown Source)
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12823
    
    5

Hmm - Java 1.4 does not have a org.w3c.dom.ls package - it only has org.w3c.dom - this indicates to me that your program requires a special library which you appear to have on your work station but not on the server.
A google search for "DOMImplementationLS" surprised me! It appears that this class is in the Java 1.5 standard library and in a variety of other places.
Here is a quote from the Java 1.5 page:
DOMImplementationLS contains the factory methods for creating Load and Save objects.

I think you should look around the results of searching for DOMImplementationLS to see if you recognize anything related to your project.
Bill
Tommy Greenberg
Greenhorn

Joined: Jul 30, 2004
Posts: 15
I thought J2SE v 1.4.2_06 SDK had the org.w3c.dom.ls package. I am not certain maybe someone can confirm this.
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12823
    
    5
Searching the latest 1.4.2 documentation at
http://java.sun.com/j2se/1.4.2/search.html
could not find any mention of DOMImplementationLS
Bill
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can't find a JAR for XML