Re: [Simple-support] jaxb's xmlseealso equivalent
Brought to you by:
niallg
|
From: Niall G. - Y. <Nia...@yi...> - 2013-03-25 22:41:58
|
You can use @Element(required=false) on the values, or you can use a Converter, which can be used to add custom logic for deserialization.. From: Shyam Sankaran [mailto:sh...@ou...] Sent: Tuesday, 26 March 2013 4:29 AM To: Simple Support Subject: [Simple-support] jaxb's xmlseealso equivalent Hi, I am consuming a web service which uses jaxb for serializing the response java objects into xml. So, I get a response like this : <things xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="thing"> <val>185</val> </things> <things xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="anotherThing"> <anotherVal>162</anotherVal> </things> The server code uses jaxb's @xmlseealso for dynamic mapping of generic list objects. My question is how am I to unmarshall this response using Simple annotations. Is there an xmlseealso equivalent in Simple. If not, what is the solution ? Should I be using an attribute 'type' for every generic collection ? Regards, Shyam |