wex
v21.10.0
|
This class offers core process. More...
#include <wex/factory/process.h>
Public Member Functions | |
process () | |
Default constructor. | |
virtual | ~process () |
Destructor, stops running process. | |
virtual bool | async_system (const std::string &exe, const std::string &start_dir=std::string()) |
Virtual interface. More... | |
const auto & | get_exe () const |
Other methods. More... | |
const auto & | get_stderr () const |
Returns the stderr. | |
const auto & | get_stdout () const |
Returns the stdout. | |
bool | is_debug () const |
Is this a debug process. | |
bool | is_running () const |
Is this process running. | |
void | set_handler_dbg (wxEvtHandler *eh) |
Sets debug event handler. | |
void | set_handler_out (wxEvtHandler *eh) |
Sets out event handler. | |
int | system (const std::string &exe, const std::string &start_dir=std::string()) |
Runs the sync process, collecting output in stdout and stderr. More... | |
This class offers core process.
|
virtual |
Virtual interface.
Starts the async process, collecting output into the out handler, and debug info in debug handler. You should have called set_handler_out or dbg before to set these. The output streams of the executing process are sent to these event handlers using wxPostEvent. Returns true if the async process is started.
Reimplemented in wex::process.
|
inline |
Other methods.
Returns last or current exe.
int wex::factory::process::system | ( | const std::string & | exe, |
const std::string & | start_dir = std::string() |
||
) |
Runs the sync process, collecting output in stdout and stderr.
It will execute the process and wait for it's exit, then return the exit_code.