Class EventManager:
provide event sending and listening. use a hashable key to identify an event.
def f(data):
print data
manager = EventManager()
manager.start() # start listen
manager.addListener(key='evnet_key', listener=f)
manager.sendEvent(key='evnet_key', data={msg:'hello'})
# other methods
manager.removeListener(key='evnet_key', f)
manager.stop() # stop listen
manager.clear() # clear event
Change Log
v0.0.2, 2018-11-8
- change to run with python3
Release files for sine.event 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| sine.event-0.0.2.tar.gz | 5.3 kB | Details |
Release files / sine.event-0.0.2.tar.gz
| Download URL | sine.event-0.0.2.tar.gz |
|---|---|
| Size | 5.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7290d045cba35fbbaf5382db533696ed6379b4fa461c3721c3cf9c7f26ce01b4
|
|
BLAKE2b-256 checksum How to use checksums |
5cba2778c948552eaf589c2a7622642eee60363cbdb54f8ed31e4ddb9c1fb778
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.0 CPython/3.7.2
|