As an example, I'd like to serialize/deseriali开发者_运维百科ze one object of Slick2d's Animation class using Jackson. What is the simplest way to do this?
You can annotate a mix-in interface if you want to control the generated json on third party classes.
read more here: http://wiki.fasterxml.com/JacksonMixInAnnotations
Update: The current documentation (v2+) is here: https://github.com/FasterXML/jackson-docs/wiki/JacksonMixInAnnotations
Just as any object - pass it to objectMapper.readValue(..)
/ objectMapper.writeValue(..)
精彩评论