asynqueue.base.Priority(object)
class documentation
Part of asynqueue.base
(View In Hierarchy)
I provide simple, asynchronous access to a priority heap.
Method | __init__ | Undocumented |
Method | shutdown | Shuts down the priority heap, firing errbacks of the deferreds of any get requests that
will not be fulfilled. |
Method | get | Gets an item with the highest priority (lowest value) from the heap,
returning a Deferred that fires when the item becomes
available. |
Method | put | Adds the supplied item to the heap, firing the oldest getter
deferred if any get calls are
pending. |
Method | cancel | Removes all pending items from the heap that the supplied
selector function selects. The function must take an item as its
sole argument and return True if it selects the item for queue
removal. |
Shuts down the priority heap, firing errbacks of the deferreds of any get
requests that
will not be fulfilled.
Gets an item with the highest priority (lowest value) from the heap,
returning a Deferred
that fires when the item becomes
available.
Adds the supplied item to the heap, firing the oldest getter
deferred if any get
calls are
pending.