Skip to main content
Archived

This project has been archived by its maintainers, and is no longer receiving any updates.

Library for easy bi-direction converting between plain JSON-like data (numbers, strings, lists and dicts) and compound user-defined classes.

Trivial example:

>>> from steward import *
>>> class Comp(Component):
...     a = Field()
...     b = Field(default=1)
...
>>> v = Comp(a=0)
>>> dct = v.as_plain()
>>> dct
{'a': 0, 'b': 1}
>>> v2 = Comp.from_plain(dct)
>>> v2.a
0
>>> v2.b
1
>>> v2.a = 7
>>> v2.as_plain()
{'a': 7, 'b': 1}

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

steward-0.0.4.tar.gz (3.9 kB view details)

Uploaded Source

File details

Details for the file steward-0.0.4.tar.gz.

File metadata

  • Download URL: steward-0.0.4.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for steward-0.0.4.tar.gz
Algorithm Hash digest
SHA256 3e1e61cd297f68fec40104532e2b78b9a4d76a540dffe9938ae763b369da3429
MD5 9352c8c66be470e9e5fe51ab9a4f49a6
BLAKE2b-256 0471b2150f5a47efa7217bfb5e1804863ba39e3530befcc8dcd9203f43890805

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.0.4 This release

1 file

0.0.3

1 file

0.0.2

1 file

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page