AUI Framework
develop
Cross-platform base for C++ UI apps
|
#include <AUI/Platform/AProcess.h>
Classes | |
struct | ArgSingleString |
Process arguments represented as a single string. More... | |
struct | ArgStringList |
Process arguments represented as array of strings. More... | |
struct | ProcessCreationInfo |
Process creation info. More... | |
Public Member Functions | |
virtual APath | getModuleName ()=0 |
virtual APath | getPathToExecutable ()=0 |
virtual uint32_t | getPid () const noexcept=0 |
virtual int | waitForExitCode ()=0 |
Wait for process to be finished and returns exit code. | |
virtual size_t | processMemory () const =0 |
Obtain process memory usage. | |
void | kill () const noexcept |
Public Member Functions inherited from aui::noncopyable | |
noncopyable (const noncopyable &)=delete | |
noncopyable & | operator= (const noncopyable &)=delete |
Static Public Member Functions | |
static _< AChildProcess > | create (ProcessCreationInfo args) |
Launches an executable. | |
static _< AChildProcess > | make (AString applicationFile, AString args={}, APath workingDirectory={}) |
Launches an executable. | |
static int | executeWaitForExit (AString applicationFile, AString args={}, APath workingDirectory={}, ASubProcessExecutionFlags flags=ASubProcessExecutionFlags::DEFAULT) |
Launches executable. | |
static void | executeAsAdministrator (const AString &applicationFile, const AString &args={}, const APath &workingDirectory={}) |
Launches executable with administrator rights. (Windows only) | |
static AVector< _< AProcess > > | all () |
static _< AProcess > | self () |
static _< AProcess > | findAnotherSelfInstance (const AString &yourProjectName) |
tempFileName file name which will be used as lock | |
static _< AProcess > | fromPid (uint32_t pid) |
Retrieves data about processes.
|
static |
Launches an executable.
args | designated-initializer-style args. See ProcessCreationInfo |
|
static |
Launches executable with administrator rights. (Windows only)
applicationFile | executable file |
args | arguments |
workingDirectory | pro |
|
static |
Launches executable.
applicationFile | executable file. |
args | arguments. |
workingDirectory | working directory. |
flags | process execution flags. see ASubProcessExecutionFlags. |
tempFileName file name which will be used as lock
|
pure virtual |
Implemented in AChildProcess, AOtherProcess, AOtherProcess, and ASelfProcess.
|
pure virtual |
Implemented in AChildProcess, AOtherProcess, AOtherProcess, and ASelfProcess.
|
pure virtualnoexcept |
Implemented in AChildProcess, AOtherProcess, AOtherProcess, and ASelfProcess.
|
inlinestatic |
Launches an executable.
applicationFile | executable file |
args | arguments |
workingDirectory | working directory |
|
pure virtual |
Obtain process memory usage.
Implemented in AChildProcess, AOtherProcess, AOtherProcess, and ASelfProcess.
|
pure virtual |
Wait for process to be finished and returns exit code.
Implemented in AChildProcess, AOtherProcess, AOtherProcess, and ASelfProcess.