Gson implementatio

Changed the way that the object classes are implemented so that they
can support gson