A decorator for adding static variables to a method.
Typical use:
from static_vars import static_vars
@static_vars(counter=0)
def foo():
foo.counter += 1
foo()
foo()
assert foo.counter==2
foo.counter = 0
foo()
assert foo.counter==1
Free software: MIT license
Documentation: https://static-vars.readthedocs.io.
Release files for static-vars 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| static_vars-0.1.0.tar.gz | 2.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| static_vars-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 4.9 kB
Release files / static_vars-0.1.0.tar.gz
| Download URL | static_vars-0.1.0.tar.gz |
|---|---|
| Size | 2.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d334ce903cd57b580cc988e3d48e3cf6515297f4bc13296ee86d53f77bbe9e07
|
|
BLAKE2b-256 checksum How to use checksums |
0041fcf9941170d9a2ee98ff58369230b750fea5b3af8d60a32703d93e9960ea
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.0.0b8 CPython/3.8.0 Darwin/19.0.0
|
Release files / static_vars-0.1.0-py3-none-any.whl
| Download URL | static_vars-0.1.0-py3-none-any.whl |
|---|---|
| Size | 2.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
73b131be0b15a9643009bd04501cf036d766de32150bd38cbeb8603d31f7721a
|
|
BLAKE2b-256 checksum How to use checksums |
303bb2693d6b6a413657d3527f7ec7a06d4af07eb9d74701e70d6ff87277673b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.0.0b8 CPython/3.8.0 Darwin/19.0.0
|