Skip to main content

A port of node.js's EventEmitter to python.

Project description

pyee supplies an event_emitter object that acts similar to the EventEmitter that comes with node.js.

Example

In [1]: from pyee import EventEmitter

In [2]: ee = EventEmitter()

In [3]: @ee.on('event')
   ...: def event_handler():
   ...:     print 'BANG BANG'
   ...:

In [4]: ee.emit('event')
BANG BANG

In [5]:

Easy-peasy.

For more, visit <https://github.com/jesusabdullah/pyee> .

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyee-topics-0.0.8.tar.gz (4.4 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page