I want to use XStream to write XML for objects that have a field that
is a Map. That gives me something like this.
<artists class="tree-map">
<no-comparator/>
<entry>
<string>some key</string>
<artist>
<!-- child elements omitted -->
</artist>
</entry>
<!-- more entry elements go here -->
</artists>
I don't want the Map information in my XML. I really want output like
this.
<artists>
<artist>
<!-- child elements omitted -->
</artist>
<!-- more artist elements go here -->
</artists>
Can I configure XStream to do this and still be able to read that XML
back in to reconstruct the objects, including the Maps? I'm imagining
that this could work if I could tell XStream which field of the Artist
objects should be used for key values in the Map.
---
Mark Volkmann