wex v24.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 process_data &data) |
Starts the async process, collecting output into the out handler, and debug info in debug handler. | |
virtual int | system (const process_data &data) |
Runs the sync process, collecting output in stdout and stderr. | |
void | async_sleep_for (const std::chrono::milliseconds &ms) |
Sleeps for some milliseconds time. | |
const process_data & | data () const |
Returns last or current data used by async_system or system. | |
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. | |
const auto & | std_err () const |
Returns the stderr. | |
const auto & | std_out () const |
Returns the stdout. | |
This class offers core process.
|
virtual |
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.
|
virtual |
Runs the sync process, collecting output in stdout and stderr.
It will execute the process and wait for it's exit, then returns the exit_code.
Reimplemented in wex::process, and wex::vcs_entry.