userver: engine::subprocess::ProcessStarter Class Reference
Loading...
Searching...
No Matches
engine::subprocess::ProcessStarter Class Reference

#include <userver/engine/subprocess/process_starter.hpp>

Detailed Description

Creates a new OS subprocess and executes a command in it.

Definition at line 28 of file process_starter.hpp.

Public Member Functions

 ProcessStarter (TaskProcessor &task_processor)
 
ChildProcess Exec (const std::string &command, const std::vector< std::string > &args, const EnvironmentVariables &env, const std::optional< std::string > &stdout_file=std::nullopt, const std::optional< std::string > &stderr_file=std::nullopt)
 env redefines all environment variables.
 
ChildProcess Exec (const std::string &command, const std::vector< std::string > &args, EnvironmentVariablesUpdate env_update, const std::optional< std::string > &stdout_file=std::nullopt, const std::optional< std::string > &stderr_file=std::nullopt)
 
ChildProcess Exec (const std::string &command, const std::vector< std::string > &args, const std::optional< std::string > &stdout_file=std::nullopt, const std::optional< std::string > &stderr_file=std::nullopt)
 Exec subprocess using current environment.
 

Member Function Documentation

◆ Exec()

ChildProcess engine::subprocess::ProcessStarter::Exec ( const std::string & command,
const std::vector< std::string > & args,
EnvironmentVariablesUpdate env_update,
const std::optional< std::string > & stdout_file = std::nullopt,
const std::optional< std::string > & stderr_file = std::nullopt )

Variables from env_update will be added to current environment. Existing values will be replaced.


The documentation for this class was generated from the following file: