steenzout.serialization.json package

Module contents

JSON serialization package.

deserialize(json, cls=None)[source]

Deserialize a JSON string into a Python object.

Parameters:
  • json (str) – the JSON string.
  • cls (object) – if the json is deserialized into a dict and this argument is set, the dict keys are passed as keyword arguments to the given cls initializer.
Returns:

Python object representation of the given JSON string.

serialize(obj)[source]

Serialize the given object into JSON.

Parameters:obj – the object to be serialized.
Returns:JSON representation of the given object.
Return type:(str)
version()[source]

Return this package version.

Returns:package version.
Return type:(str)