Performance improvement for JS Statement.equals

* wb.Claim equal adjusted as well, checking whether given instance has same constructor.
* also added TODOs for all the toJSON and newFromJSON to implement them, using the new
  serialization system.

- patch set 3: rebase

Change-Id: Ia782a47a85e09b358eab46762fbaff4d6bf37a53