Custom JSONEncoder & JSONDecoder
Compare changes
This MR adds custom JSONEncoder
and JSONDecoder
that handles non-standard JSON values used by the go client.
BigInt
values in JSON at key Value
by converting them to/from String
.JSONEncodingError
and JSONDecodingError
for extra verbose output when debugging JSON coding-related issues.The JSONEncoder
and JSONDecoder
are internal, to avoid name collisions when using the XXClient
library as a dependency, but internally all models are encoded/decoded using the custom encoder/decoder. Convenient encode
and decode
methods on each model remain public.