Generate templated objects
Project description
embody
Generate templated objects
To install: pip install embody
Examples
>>> from embody.templater import Templater
>>> # the following template has templated dicts, strings, and lists
>>> template = {
... 'hello': '{name}',
... 'how are you': ['{verb}', 2, '{name} and {verb} again']
... }
>>> g = Templater.template_func(template=template)
>>> g(name='NAME', verb="VERB")
{'hello': 'NAME', 'how are you': ['VERB', 2, 'NAME and VERB again']}
>>> str(g.__signature__)
'(*, name, verb)'
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
embody-0.1.6.tar.gz
(26.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
embody-0.1.6-py3-none-any.whl
(23.2 kB
view details)
File details
Details for the file embody-0.1.6.tar.gz.
File metadata
- Download URL: embody-0.1.6.tar.gz
- Upload date:
- Size: 26.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
602ed95a7839bc198445bcba3696e3b71cc6b80877a81defeedceab7b1394b70
|
|
| MD5 |
be8a87549b0fd5ddad221c69f237f321
|
|
| BLAKE2b-256 |
5b1b2f432a17931c2e9ae863355f6903c74dd68067ab35fb7cbdf44d93160c53
|
File details
Details for the file embody-0.1.6-py3-none-any.whl.
File metadata
- Download URL: embody-0.1.6-py3-none-any.whl
- Upload date:
- Size: 23.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e159f2a6979871c5b647a6b00fcd7d592f06af615543926f59f476fb463da4fd
|
|
| MD5 |
10667818d0e305913e3a679d7e2312f7
|
|
| BLAKE2b-256 |
55518e3c9f718183728d1b780fc927a448980637178a43728482383d7d1e624e
|