VICI
0.11.815
Visual Chart Interpreter
|
Represents the state of a child process. More...
#include <vici/proc.h>
Public Member Functions | |
ChildProcess (const std::string &cmnd, int *fdin=nullptr, int *fdout=nullptr, int *fderr=nullptr) | |
constructor More... | |
ChildProcess () | |
constructor for fork | |
virtual | ~ChildProcess () |
destructor | |
virtual void | setArgs (const std::vector< std::string > &args) |
set the args for the process More... | |
virtual void | run () |
start the command running | |
virtual void | kill () |
terminate the process | |
virtual int | signal (int sig) |
send a signal to the process | |
virtual void | finished (int result) |
set the exit status of the process More... | |
bool | done () |
get the running status of the program | |
virtual int | getId () |
get the process id | |
int | getExitSignal () |
get the signal that caused the process to exit. | |
int | getExitStatus () |
get the exit status | |
void | reportExitErrors (bool x) |
turn on or off the reporting of error exits | |
Public Member Functions inherited from VICI::cfi::AbstractChildProcess | |
virtual | ~AbstractChildProcess () |
Destructor. | |
Represents the state of a child process.
ChildProcess::ChildProcess | ( | const std::string & | cmnd, |
int * | fdin = nullptr , |
||
int * | fdout = nullptr , |
||
int * | fderr = nullptr |
||
) |
constructor
cmnd | the command to run |
fdin | File descriptor for stdin for the child |
fdout | File descriptor for stdout for the child |
fderr | File descriptor for stderr for the child |
|
virtual |
set the exit status of the process
called by the process manager when the process exits
result | the exit status and code of the process |
Implements VICI::cfi::AbstractChildProcess.
|
virtual |
set the args for the process
args | the args for the command |