I have something like the following model in Hibernate:
class Person {
String name;
List addresses;
}
class Address {
String stre
I haven't tried myself but here is a blog which is worth referring to... https://dzone.com/articles/annotating-custom-types
Which basically suggests you to add a custom annotation. The annotated class for example call it "AddressJSONParser" should convert your Address object to JSON (using parser's) and returns as String. You should also a think about having a parser which does the reverse, from JSON string back to Address object...