Sunday, August 14, 2011

Gson inheritance

This article helped fix a problem I had with inheritance, and Gson (JSON api)

http://www.velvetcache.org/2011/01/24/gson-inheritance-issues


Basically, key is to ensure that you specify the field values as private fields, and assign their values in the constructor (not by creating a new private field with an updated value)

No comments: