Models for working with JSON, ie: JsonModel
Project description
Json Modeling Library
Provides easy way to map dict to/from Full-Fledged 'JsonModel' object.
Documentation
📄 Detailed Documentation | 🐍 PyPi
Getting Started
???+ warning "Alpha Software!" This is pre-release Alpha software, based on another code base and the needed changes to make a final release version are not yet completed. Everything is subject to change!
poetry install xmodel
or
pip install xmodel
Very basic example:
from xmodel import JsonModel
class MyModel(JsonModel):
some_attr: str
json_dict_input = {'some_attr': 'a-value'}
obj = MyModel(json_dict_input)
assert obj.some_attr == 'a-value'
json_dict = obj.api.json()
assert json_dict == json_dict_input
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 Distribution
xmodel-0.5.0.tar.gz
(81.2 kB
view details)
Built Distribution
xmodel-0.5.0-py3-none-any.whl
(92.6 kB
view details)
File details
Details for the file xmodel-0.5.0.tar.gz
.
File metadata
- Download URL: xmodel-0.5.0.tar.gz
- Upload date:
- Size: 81.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.10.6 Linux/5.15.0-1036-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a3bd56a137763b7b0607b520caf93919d0c8bfacc6a16916c136610e794514d6 |
|
MD5 | 4361b61376464e5177507b000abf4252 |
|
BLAKE2b-256 | 2889c337ad186652bb7a0ce8732784df4730d5ca39e487a984a0acecc28d3a4d |
File details
Details for the file xmodel-0.5.0-py3-none-any.whl
.
File metadata
- Download URL: xmodel-0.5.0-py3-none-any.whl
- Upload date:
- Size: 92.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.4.2 CPython/3.10.6 Linux/5.15.0-1036-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c5dec84d00d4041ce0c207e8e3975b7997854192b79f8577e1bbda2f1e58256e |
|
MD5 | 2c92f6edc5e3b84f9be7fe5bec681611 |
|
BLAKE2b-256 | 84f7285f3b1c0142802a352dac1a4c19183f41787325fe89b8d3fc5233b88cac |