Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var CodecHandle *codec.JsonHandle
CodecHandle is used to instantiate JSON encoders and decoders with our settings (canonical, paranoid about decoding errors)
var JSONStrictHandle *codec.JsonHandle
JSONStrictHandle is the same as CodecHandle but with MapKeyAsString=true for correct maps[int]interface{} encoding
var LenientCodecHandle *codec.JsonHandle
LenientCodecHandle is used to instantiate msgpack encoders for the REST API.
Functions ¶
func Decode ¶
Decode attempts to decode a json-encoded byte buffer into an object instance pointed to by objptr
func Encode ¶
func Encode(obj interface{}) []byte
Encode returns a json-encoded byte buffer for a given object
func EncodeStrict ¶
func EncodeStrict(obj interface{}) []byte
EncodeStrict returns a JSON-encoded byte buffer for a given object It is the same Encode but encodes map's int keys as strings
func LenientDecode ¶
LenientDecode attempts to decode a json-encoded byte buffer into an object instance pointed to by objptr
Types ¶
This section is empty.