| Home | Trees | Index | Help |
|
|---|
| Package pyVerif :: Module Executor :: Class Executor |
|
Management of running commands.
If you want to run some system commands, and have control on them, you could use this class. The stdout could be outputed to either the screen or a specified file (or both). The stderr is always outputed to the screen. It could also be outputed to a file.| Method Summary | |
|---|---|
__init__(self)
| |
Enable or disable the logs. | |
Log the given message. | |
Log info relative to the current computer. | |
Runs the given command, with the given arguments. | |
Returns timing information. | |
| Method Details |
|---|
enable_log(self, on_screen=True, filename=None)Enable or disable the logs. - on_screen controls the logging of the messages on the screen. It controls only the stdout. The stderr is _always_ displayed on the screen. - if filename is specified, stdout and stderr are cloned in the given file. If the given file exists, it is overwritted. |
log(self, msg)Log the given message. The message could be outputed to the screen and/or the output file, depending on what the user has choose previously with enable_log (). |
log_info(self)Log info relative to the current computer. |
run(self, cmd, args)Runs the given command, with the given arguments. Raise an exception in case of problem. |
timing(self)Returns timing information. Returns a tuple with two values: - the time since the creation of the current object, - the time since the begin of the last run. Both times are in milliseconds. |
| Home | Trees | Index | Help |
|
|---|
| Generated by Epydoc 2.1 on Fri Oct 6 12:25:10 2006 | http://epydoc.sf.net |