Tags

,

links:
http://stackoverflow.com/questions/12911953/how-to-wrap-sublist-with-jaxb

summary:
– @XmlElementWrapper adds an “extra” element to wrap around a list ?


@XmlElementWrapper(name="tablewrapper")
@XmlElement(name="table") // without this line, jaxb would use "tablelist"
ArrayList<Table> tablelist = new ArrayList<Table>(0); 


This would be marshalled into:
:
<tablewrapper>
  <table>
  :
  </table>
</tablewrapper>

Advertisements