powerful and useful decorations
Project description
useful-decoration
Description
I wrote some decorators that are commonly used in my daily work. And I gave an example if the decorator is often used.
Installing
Install and update using pip:
pip install useful-decoration
Simples
from useful_decoration.decorations import element_mapping
class Person:
def __init__(self, name):
self.name = name
@element_mapping(factor_name="factor")
def calculate(self):
return 10
if __name__ == '__main__':
p = Person(name='frank')
print(p.calculate()) # {'factor': 10}
Contributes
Welcome, you can join this repo to enhance this repo together. you can pull request to me . please don’t hesitate to contact with me if you have any questions .
Links
pypi address https://pypi.org/project/useful-decoration/
Documentation: https://useful-decoration.readthedocs.io/en/latest/
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
Built Distribution
Close
Hashes for useful_decoration-1.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5155fce4da459b3647ceae27772347c641ba464179232cb63d85dce8c15813b0 |
|
MD5 | 9b33e3d45970bc47074c1bb32b39ae12 |
|
BLAKE2b-256 | 052f4f5ed372dd3e020ecc3e1b9929c5543f6b894cb9d2a9ea72af5cacdc097b |