aspose file tools*
The moose likes Web Services and the fly likes Need help with JAXB Unmarshal xml data Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "Need help with JAXB Unmarshal xml data" Watch "Need help with JAXB Unmarshal xml data" New topic
Author

Need help with JAXB Unmarshal xml data

laura mccord
Ranch Hand

Joined: Feb 10, 2009
Posts: 108
This is a real-world example where I have an xml document where there is an element <XML_ELEMENT> that I wish I could ignore and just go straight to <PEOPLE> and <PERSON>. Most examples I see don't have this extra wrapper. I don't know if there is a way in my Persons class through annotations to target <PERSONS> without being blocked by <XML_ELEMENT> below. This has me so frustrated because I know there is probably an easy way to do this but I don't know what to search for.... please help.









Many Thanks
laura mccord
Ranch Hand

Joined: Feb 10, 2009
Posts: 108
Oh my goodness I found it....@XmlElementWrapper is what I needed. I knew it was an annotation that I needed.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Need help with JAXB Unmarshal xml data