Forums Register Login

JAXB Unmarshalling

+Pie Number of slices to send: Send
Hi,

I am trying for unmarshalling with JAXB. I am getting an error msg
Exception in thread "main" javax.xml.bind.JAXBException
- with linked exception:
[java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory]
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:196)
at javax.xml.bind.ContextFinder.find(ContextFinder.java:385)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:574)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:522)
at com.jax.PersonUnmarshaller2.main(PersonUnmarshaller2.java:24)
Caused by: java.lang.ClassNotFoundException: com.sun.xml.bind.v2.ContextFactory
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:192)
... 4 more

Am i missing something
Can somebody help me in solving this issue?
+Pie Number of slices to send: Send
Hi!
Make sure you have a JAR file containing JAXB implementation, such as jaxb-impl-2.1.5.jar, on your classpath.
The missing class is supposed to be located in the JAXB implementation JAR.
Best wishes!
+Pie Number of slices to send: Send

Thank you Ivan. It works now.

Regards,
Teena
It's never done THAT before. Explain it to me tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 6752 times.
Similar Threads
java.lang.SecurityException: sealing violation
JAXBContext - IncompatibleClassChangeError
Problem while connecting to UDDI registry
New to Web Services and JAXB
Provider com.sun.org.apache.xerces.internagsl.jaxp.datatype.DatatypeFactoryImpl not found
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 19:57:43.