[SWS-224] XStreamMarshaller is missing the call to omit fields from serialization process Created: 06/Nov/07  Updated: 04/May/12  Resolved: 23/Jul/08

Status: Closed
Project: Spring Web Services
Component/s: OXM
Affects Version/s: None
Fix Version/s: 1.5.4

Type: Improvement Priority: Major
Reporter: Kostya Assignee: Tareq Abedrabbo
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: Text File SWS-224.patch    

 Description   

XStreamMarshaller is missing the ability to omit fields from been serialized / deserialized even though underling xstream library has it..

We currently are working around the issue by using reflection. It is though rather a hack.

I propose to add method addOmitField(My.class, "field name") or something along those lines



 Comments   
Comment by Tareq Abedrabbo [ 22/Jul/08 ]

Patch + unit tests.
Added:

  • a simple addOmittedField method
  • setOmittedFieldsMap taking a map of classes mapped to arrays of String field names
  • setOmittedFields taking a map of classes mapped to comma separated field names as setOmittedFieldsMap might be too verbose in XML configuration files.
    setOmittedFieldsMap and setOmittedFields are quite similar and maybe keeping only one of them is enough.
Comment by Arjen Poutsma [ 04/May/12 ]

Closing old issues

Generated at Sun Dec 17 11:58:46 UTC 2017 using JIRA 6.4.14#64029-sha1:ae256fe0fbb912241490ff1cecfb323ea0905ca5.