Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

runtime error: unsupport new jaxp?

0 views
Skip to first unread message

John

unread,
Jun 13, 2002, 10:41:23 AM6/13/02
to
I got problem after installing the fresh jaxp, hope anyone can help me
out

I'm using java1.4 (installed half year ago), but recently dowonloaded
and installed sun-xml-jaxp-summer-2, and tried to build a dom as
follow:

import org.w3c.dom.*;
import javax.xml.parsers.*;
DocumentBuilder builder =
DocumentBuilderFactory.newInstance().newDocumentBuilder();
Document doc = builder.parse( xmlFile );

There was NOT any error with compiler (javac or jikes), but while
running the compiled code, it said:

Exception in thread "main" java.lang.UnsupportedClassVersionError:
javax/xml/parsers/DocumentBuilderFactory (Unsupported major.minor
version 48.0)
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:486)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:248)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:297)
....


Does anyone know how to fix it?


Thanks lots.

John

Chris Smith

unread,
Jun 13, 2002, 10:51:41 AM6/13/02
to
John wrote ...

> I got problem after installing the fresh jaxp, hope anyone can help me
> out
>
> I'm using java1.4 (installed half year ago)

Are you sure about this? IIRC the Java 1.4 VM should have no problem
reading a class file of version 48.0. This error would make perfect
sense, on the other hand, if you were accidentally running the code in an
earlier version of the JVM that's left over from a previous install.

Chris Smith

0 new messages