This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes Java in General and the fly likes JAXBContext  - IncompatibleClassChangeError Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "JAXBContext  - IncompatibleClassChangeError" Watch "JAXBContext  - IncompatibleClassChangeError" New topic

JAXBContext - IncompatibleClassChangeError

sarah Marsh
Ranch Hand

Joined: Mar 06, 2001
Posts: 282

Please help! What could be the problem?

I got the running time error for the following code:
JAXBContext jc = JAXBContext.newInstance( "" );

java.lang.IncompatibleClassChangeError: Implementing class
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(
at com.evermind.naming.ContextClassLoader.defineClass(
at com.evermind.naming.ContextClassLoader.findClass(
at java.lang.ClassLoader.loadClass(
at java.lang.ClassLoader.loadClass(
at java.lang.ClassLoader.loadClassInternal(
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(
at com.evermind.server.ApplicationContextClassLoader.findClass(
at java.lang.ClassLoader.loadClass(
at java.lang.ClassLoader.loadClass(
at com.sun.xml.bind.ContextFactory_1_0_1.createContext(
at java.lang.reflect.Method.invoke(Native Method)
at javax.xml.bind.ContextFinder.newInstance(
at javax.xml.bind.ContextFinder.searchcontextPath(
at javax.xml.bind.ContextFinder.find(
at javax.xml.bind.JAXBContext.newInstance(
at javax.xml.bind.JAXBContext.newInstance(

Mattias Arthursson
Ranch Hand

Joined: Jul 26, 2004
Posts: 90
IncompatibleClassChangeError javadoc

Seems like you compiled your program using a different version of the library than the one you're using when you run the program. Check the build classpath and compare it to the run classpath.

Admit nothing. Blame everyone. Be bitter.
wood burning stoves
subject: JAXBContext - IncompatibleClassChangeError
jQuery in Action, 3rd edition