How to customise the Jackson JSON mapper in Spring Web MVC
How to customise the Jackson JSON mapper in Spring Web MVC
Spring MVC using annotations is great for AJAX + JSON until you need to customise the JSON mapping.
If you are using Spring 3.1 take a look at configuring a message converter as part of mvc namespace config for a more elegant solution.
There is an option to add annotations directly to your model classes, but if you want to keep them separate you can do the following:
Read full article from How to customise the Jackson JSON mapper in Spring Web MVC
No comments:
Post a Comment