• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

JAXB sample in the JWSDP1.3

 
Ranch Hand
Posts: 1011
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I tried to use the JWSDP1.3 and tried to get the first example unmarshal-read running.
Used the ant to build it without problem.
Then I saw a Main.class was created under c:\jwsdp-1.3\jaxb\samples\unmarshal-read

Then under the same place, I tried to type in the commandline:
java Main
Then got the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException
Anyone gets any ideas?
Thanks!
 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i believe most of the build.xmls in the samples have a task named run as well so do an "ant run" and it should work. otherwise manually place the jaxb libs on your classpath and run them
 
Tong Chen
Ranch Hand
Posts: 1011
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I used:
java -classpath C:\jwsdp-1.3\jaxb\lib\*.jar; C:\jwsdp-1.3\jwsdp-shared\lib\*.jar Main
don't work?
 
Ranch Hand
Posts: 418
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
try putting individual jar file names in classpath instaed of *.jar.
 
Run away! Run away! Here, take this tiny ad with you:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic