adt4j
adt4j copied to clipboard
JSON serialization and deserialization?
I figure serialization should be pretty trivial with object mapping solutions such as Gson and Jackson
But deserialization (at least in Jackson) requires some boilerplate + some type information in the JSON tree itself (http://www.studytrails.com/java/json/java-jackson-Serialization-polymorphism.jsp)
Do you have any thoughts on this?
I don't know the answer to your question. You can try to tinker with custom TypeIdResolvers to implement deserialization.
At first it seems easier to include required annotations to generated code, but it may be better to feather explorer the problem and try to find more extensible solution that can be adapted to other serialization frameworks...