Functional programming is nice and all, but there are overheads related to them.
Added support for custom methods to serialize and de-serialize objects, with the 'toJson' method and 'fromJson' constructor.