Does Jackson2 provide something similar to JAX-B's Marshaller/Unmarshaller Listener?

前端 未结 1 1690
青春惊慌失措
青春惊慌失措 2021-01-25 20:41

I have a need in certain cases to alter the serialized/deserialized value while marshalling/unmarshalling JSON using Jackson2.

Does there exist a mechanism similar to ja

相关标签:
1条回答
  • 2021-01-25 20:59

    No. There have been requests for post-processing hooks, esp. for deserialization, but no implementation yet.

    Jackson 2.2 will come with Converter annotation (@JsonSerialize(converter=MyConverter.class), @JsonDeserialize(converter=...)) which could perhaps be used for similar purpose. This is similar to JAXB XmlJavaAdapter.

    0 讨论(0)
提交回复
热议问题