Im upgrading the xstream lib from 1.3 to 1.4.20.
Sometimes i’m deserilizing an empty collection with no wrapper. With version 1.4.20 that is turned into null instead of an empty collection, which is what I want.
How do I get an empty collection from and optional field not being present in the XML.
I have added the required
xstream.allowTypes(new Class[]{…})
I have tried to add the @XStreamImplicit annotation.
New contributor
Klaus Christiansen is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.