Package threadutils :: Class ThreadPool
[hide private]
[frames] | no frames]

Class ThreadPool

source code

ThreadPoolMixIn --+
                  |
    Queue.Queue --+
                  |
                 ThreadPool

Create at most |maxthreads| to retrieve sites. It must be used with Queue |get| (get a ThreadFetch) and |put| (return the thread) methods.

Instance Methods [hide private]
 
__del__(self) source code
 
__getstate__(self) source code
 
__init__(self, maxthreads, can_grow=True)
Create a pool of threads
source code
 
close(self)
Close the ThreadPool object
source code

Inherited from ThreadPool'.ThreadPoolMixIn: _init_, begin, end, execute, put_block

Inherited from Queue.Queue: empty, full, get, get_nowait, join, put, put_nowait, qsize, task_done

Inherited from Queue.Queue (private): _empty, _full, _get, _init, _put, _qsize

Method Details [hide private]

__init__(self, maxthreads, can_grow=True)
(Constructor)

source code 
Create a pool of threads
Overrides: Queue.Queue.__init__

close(self)

source code 
Close the ThreadPool object
Overrides: ThreadPool'.ThreadPoolMixIn.close