Replies: 2 comments
-
This Stackoverflow question has some answers that may help. |
Beta Was this translation helpful? Give feedback.
-
While I can see why this might be desireable, there is one immediate thing that makes me think it's a rat hole, and not something I'd want to climb into -- deserialization of "default value", One alternative possibility, however, could be allowing "provider" style object to be specified. That would require 2 new properties for |
Beta Was this translation helpful? Give feedback.
-
It would be nice if we were able to annotate fields with something like
@IfNull(value = "methodName" )
private String genericfield
the value of the field when serialised would be whatever value that the method returns.
Beta Was this translation helpful? Give feedback.
All reactions