[Simple-support] Element/Attribute Default Values
Brought to you by:
niallg
|
From: Keith B. <ka...@gm...> - 2007-06-11 17:33:20
|
I have a situation where a field isn't required, but when it's null and is serialized, the tag still needs to show up empty. Specifically, there is a String field (webAddress) that has an Attribute annotation, that went it's null should be serialized to <webAddress/>, instead of not showing up. Is there a way to intercept the serializing of an Element/Attribute, and based upon it's type, serialize a default value? |