METADATA 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. Metadata-Version: 2.1
  2. Name: blinker
  3. Version: 1.7.0
  4. Summary: Fast, simple object-to-object and broadcast signaling
  5. Keywords: signal,emit,events,broadcast
  6. Author-email: Jason Kirtland <jek@discorporate.us>
  7. Maintainer-email: Pallets Ecosystem <contact@palletsprojects.com>
  8. Requires-Python: >=3.8
  9. Description-Content-Type: text/x-rst
  10. Classifier: Development Status :: 5 - Production/Stable
  11. Classifier: Intended Audience :: Developers
  12. Classifier: License :: OSI Approved :: MIT License
  13. Classifier: Operating System :: OS Independent
  14. Classifier: Programming Language :: Python
  15. Classifier: Topic :: Software Development :: Libraries
  16. Project-URL: Chat, https://discord.gg/pallets
  17. Project-URL: Documentation, https://blinker.readthedocs.io
  18. Project-URL: Homepage, https://blinker.readthedocs.io
  19. Project-URL: Issue Tracker, https://github.com/pallets-eco/blinker/issues/
  20. Project-URL: Source Code, https://github.com/pallets-eco/blinker/
  21. Blinker
  22. =======
  23. Blinker provides a fast dispatching system that allows any number of
  24. interested parties to subscribe to events, or "signals".
  25. Signal receivers can subscribe to specific senders or receive signals
  26. sent by any sender.
  27. .. code-block:: pycon
  28. >>> from blinker import signal
  29. >>> started = signal('round-started')
  30. >>> def each(round):
  31. ... print(f"Round {round}")
  32. ...
  33. >>> started.connect(each)
  34. >>> def round_two(round):
  35. ... print("This is round two.")
  36. ...
  37. >>> started.connect(round_two, sender=2)
  38. >>> for round in range(1, 4):
  39. ... started.send(round)
  40. ...
  41. Round 1!
  42. Round 2!
  43. This is round two.
  44. Round 3!
  45. Links
  46. -----
  47. - Documentation: https://blinker.readthedocs.io/
  48. - Changes: https://blinker.readthedocs.io/#changes
  49. - PyPI Releases: https://pypi.org/project/blinker/
  50. - Source Code: https://github.com/pallets-eco/blinker/
  51. - Issue Tracker: https://github.com/pallets-eco/blinker/issues/