Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
    Bookmark Topic Watch Topic
  • New Topic

How to create a JAXB Context from File System

 
Shaan Shar
Ranch Hand
Posts: 1249
Java Spring Ubuntu
  • Mark post as helpful
  • send pies
  • Report post to moderator
Hi I was writing an unmarshaller for JAXB, but for that first I need to create a JAXB Context.

Here is the sample code I am using





Now if I am trying to run this Main class from c:\temp\doc\testproject and my JAXB Objects are somewhere else, how can I create a JAXB Context for that packge.
If I am doing the same code at the same folder where JAXB objects are kept then it's working fine but with different folder it's not working.Please check at line 28 and 29.

Please let me know if you didn't understand the issue exactly.

Thanks
Ankur
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65335
97
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please continue any discussion in the XML forum.
 
    Bookmark Topic Watch Topic
  • New Topic