PyJackson is a serialization library based on type hinting
Project description
PyJackson is a serialization library based on type hinting
Example
Just type hint __init__ and you are ready to go:
import pyjackson class MyPayload: def __init__(self, string_field: str, int_field: int): self.string_field = string_field self.int_field = int_field pyjackson.serialize(MyPayload('value', 10)) # {'string_field': 'value', 'int_field': 10} pyjackson.deserialize({'string_field': 'value', 'int_field': 10}, MyPayload) # MyPayload('value', 10)
More features and examples here and in examples dir.
Installation
pip install pyjackson
Documentation
Development
To run all tests run:
tox
Licence
Free software: Apache Software License 2.0
Changelog
0.0.6 (2019-10-02)
Added Tuple[X, Y] and Tuple[X, …] support
0.0.5 (2019-09-30)
Fixed comparison of serializers
0.0.4 (2019-09-17)
Added some examples and minor fixes
0.0.3 (2019-09-17)
First release on PyPI.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for pyjackson-0.0.6-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 652d46d2197d5d9c79264934ff55e8a2a14ed002327273185c629ef3990ffff7 |
|
MD5 | b5a4218c3d9a66e460ae9a21f5b289f7 |
|
BLAKE2b-256 | 54fda92b6f183e7c12dfe828ce8d1baa0b640a249391d84db55b5a6ac5a54f0a |