anyflow-0.2.0
توضیحات
a simplest common middleware framework for python.
| ویژگی | مقدار |
|---|---|
| سیستم عامل | - |
| نام فایل | anyflow-0.2.0 |
| نام | anyflow |
| نسخه کتابخانه | 0.2.0 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Cologler |
| ایمیل نویسنده | skyoflw@gmail.com |
| آدرس صفحه اصلی | - |
| آدرس اینترنتی | https://pypi.org/project/anyflow/ |
| مجوز | MIT |
# anyflow
a simplest common middleware framework for python.
## HOW-TO-USE
``` py
from anyflow import Flow
flow = Flow()
@flow.use()
def middleware_1(ctx, next):
ctx.state['value'] = 1
# call the next middleware (middleware_2):
return next()
@flow.use()
def middleware_2(ctx, next):
print(ctx.state['value'])
# next middleware does not exists, call nothing:
return next()
flow.run()
```
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=3.8,<4.0 | Python |
نحوه نصب
نصب پکیج whl anyflow-0.2.0:
pip install anyflow-0.2.0.whl
نصب پکیج tar.gz anyflow-0.2.0:
pip install anyflow-0.2.0.tar.gz