Let's say I have a bean structure not generated from an XSD by JAXB, but which is FAIRLY close to the XML structure. Is there some annotation way I can direct JAXB how to unmarshal from XML to a library of legacy beans by using annotations?
A little more detail. Let's say I have an XML document that looks like:
I want to bind it to an object that has a List<String> as a property. I can add annotations easily, but don't want to unwind the code that references the java object, and the XML is being produced by a third party. I am daydreaming of an annotation that allows me to tell JAXB that it should dump the text node from each listitem node into the List<String>. I have a variety of similar things, but am hoping that once I see how one is done, i can extrapolate to other situations.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com