55 Process(
const std::filesystem::path& path,
const std::vector<std::string>& args = {});
65 const std::filesystem::path&
getPath()
const;
114 mutable std::mutex m_mutex;
115 std::filesystem::path m_path;
116 std::vector<std::string> m_args;
121 std::string m_output;
122 std::thread m_watchThread;
126 PROCESS_INFORMATION m_pi;
An event that can have handlers subscribe to it, which in turn will be called when the event is invok...
Definition event.h:49
A managed process.
Definition process.h:47
bool isRunning() const
Gets whether or not the process is running.
Process(const std::filesystem::path &path, const std::vector< std::string > &args={})
Constructs a Process.
~Process()
Destructs a Process.
bool start()
Starts the process.
int getExitCode() const
Gets the exit code of the process.
bool kill()
Kills the process.
const std::string & getOutput() const
Gets the console output of the process.
Events::Event< ProcessExitedEventArgs > & exited()
Gets the event for when the process has exited.
int waitForExit()
Waits for the process to exit.
const std::filesystem::path & getPath() const
Gets the path of the process.
bool hasCompleted() const
Gets whether or not the process has completed.
Definition deploymentmode.h:27