API Reference
Class
ServiceProcessRunner
Runs service-related executables and captures output.
Inheritance
- Object
- ServiceProcessRunner
Methods
Run 3 overloads
public static ServiceProcessResult Run(String fileName, IEnumerable<String> arguments, Nullable<TimeSpan> timeout = null) #Returns:
ServiceProcessResultExecutes the specified process and captures output.
Parameters
- fileName System.String
- Executable path.
- arguments System.String
- Arguments to pass.
- timeout System.Nullable{System.TimeSpan} = null
- Maximum time to wait for completion.
Returns
Process execution result.
Run(System.String fileName, System.Collections.Generic.IEnumerable{System.String} arguments, System.Nullable{System.TimeSpan} timeout) #Executes the specified process and captures output.
Parameters
- fileName System.String
- Executable path.
- arguments System.Collections.Generic.IEnumerable{System.String}
- Arguments to pass.
- timeout System.Nullable{System.TimeSpan}
- Maximum time to wait for completion.
Returns
Process execution result.
public static ServiceProcessResult Run(String fileName, IEnumerable<String> arguments, IReadOnlyDictionary<String, String> environmentVariables, Nullable<TimeSpan> timeout = null) #Returns:
ServiceProcessResultExecutes the specified process and captures output.
Parameters
- fileName System.String
- Executable path.
- arguments System.Collections.Generic.IEnumerable{System.String}
- Arguments to pass.
- environmentVariables System.Collections.Generic.IReadOnlyDictionary{System.String,System.String}
- Additional environment variables for the process.
- timeout System.Nullable{System.TimeSpan} = null
- Maximum time to wait for completion.
Returns
Process execution result.