Package schrodinger :: Package job :: Module queue :: Class PriorityQueue
[hide private]
[frames] | no frames]

Class PriorityQueue

object --+
         |
        PriorityQueue

This is a general priority queue.

Instance Methods [hide private]
 
__init__(self)
x.__init__(...) initializes x; see help(type(x)) for signature
 
__len__(self)
 
__iter__(self)
Note that this method is only meant to provide access to the items in the queue, and that it does not return them in sorted order.
 
push(self, item)
Add an item to the heap.
 
pop(self)
Get the highest priority item, removing it from the heap.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

push(self, item)

 

Add an item to the heap. This item must have a __lt__ method as per the heapq module requirement.