shellbot.updaters.queue module¶
-
class
shellbot.updaters.queue.
QueueUpdater
(engine=None, **kwargs)[source]¶ Bases:
shellbot.updaters.base.Updater
Writes inbound events to a queue
This updater serializes events and write them to a queue.
An event may be a Message, a Join or Leave notification, or any other Event.
Updaters expose a filtering function that can be connected to the inbound flow of events handled by the Listener.
Example:
updater = QueueUpdater(queue=Queue()) listener = Listener(filter=updater.filter)
Of course, some process has to grab content from updater.queue afterwards.