| Home | Trees | Index | Help |
|---|
| Package qm :: Package test :: Module command_thread :: Class CommandThread |
|
object--+ |_Verbose--+ |Thread--+ | CommandThread
A 'CommandThread' is a thread that executes commands.
The commands are written to a 'Queue' by a controlling thread. The 'CommandThread' extracts the commands and dispatches them to derived class methods that process them. This class is used as a base class for thread classes used by some targets.
The commands are written to the 'Queue' as Python objects. The normal commands have the form '(method, descriptor, context)' where 'method' is a string. At present, the only value used for 'method' is '_RunTest'. In that case 'descriptor' is a test descriptor and 'context' is a 'Context'. The 'Stop' command is provided as a simple string, not a tuple.| Method Summary | |
|---|---|
Construct a new 'CommandThread'. | |
Return the 'Target' associated with this thread. | |
Execute the thread. | |
Run the test given by 'descriptor'. | |
Stop the thread. | |
| Inherited from Thread | |
| |
| |
| |
| |
| |
| |
| |
| |
| Inherited from object | |
x.__delattr__('name') <==> del x.name | |
x.__getattribute__('name') <==> x.name | |
x.__hash__() <==> hash(x) | |
T.__new__(S, ...) -> a new object with type S, a subtype of T | |
helper for pickle | |
helper for pickle | |
x.__setattr__('name', value) <==> x.name = value | |
x.__str__() <==> str(x) | |
| Method Details |
|---|
__init__(self,
target)
|
GetTarget(self)Return the 'Target' associated with this thread. returns -- The 'Target' with which this thread is associated. Derived classes must not override this method. |
run(self)Execute the thread.
|
RunTest(self, descriptor, context)Run the test given by 'descriptor'. 'descriptor' -- The 'TestDescriptor' for the test to be run. 'context' -- The 'Context' in which to run the test. This method is called by the controlling thread. Derived classes must not override this method. |
Stop(self)Stop the thread. Derived classes must not override this method. |
| Home | Trees | Index | Help |
|---|
| Generated by Epydoc 2.1 on Thu Sep 27 15:49:00 2007 | http://epydoc.sf.net |