I want to include objects from 3 different classes in one xml.
I am planning to created another class to hold a list of these objects.
I need only subset of values from these objects.
Is there a way to omit few values while generating xml from XStream?
Thanks.
Try using the @XStreamOmitField annotation.
Take a look at the documentation here: http://x-stream.github.io/annotations-tutorial.html#OmitField
The below is from the documentation: