https://github.com/dolph/relish
Serialize your python objects into tasty (human-readable) formats.
https://github.com/dolph/relish
Last synced: about 1 month ago
JSON representation
Serialize your python objects into tasty (human-readable) formats.
- Host: GitHub
- URL: https://github.com/dolph/relish
- Owner: dolph
- Created: 2011-12-10T16:01:58.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2011-12-10T21:25:40.000Z (over 13 years ago)
- Last Synced: 2025-02-10T01:41:22.371Z (3 months ago)
- Language: Python
- Homepage:
- Size: 97.7 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Relish: Tasty Python Object Serialization
=========================================Serialize your python objects into tasty (human-readable) formats.
- Serialize your python object models to/from JSON, YAML or XML.
- Customize the appearance of the serialized data, e.g. for RESTful consumption.Examples
-------->>> @relish
... class Foobar():
... @relish
... my_attribute = 'my_value'
...
>>> x = Foobar()
>>> jsonify.serialize(x)
'{"foobar": {"my_attribute": "my_value"}}'
>>> jsonify.deserialize(_)
<__main__.Foobar instance at 0x10046cf38>