C# 클래스 System.Diagnostics.Process

상속: System.ComponentModel.Component
파일 보기 프로젝트 열기: dotnet/corefx 1 사용 예제들

Private Properties

프로퍼티 타입 설명
BootTimeToDateTime System.DateTime
BuildCommandLine StringBuilder
CloseCore void
CloseMainWindowCore bool
ConfigureAfterProcessIdSet void
CreateEnvp string[]
CreatePipe void
CreatePipeWithSecurityAttributes void
EnsureHandleCountPopulated void
EnvironmentVariablesToByteArray byte[]
GetCurrentProcessId int
GetCurrentProcessRUsage Interop.libproc.rusage_info_v3
GetEncoding System.Text.Encoding
GetExePath string
GetMainWindowTitle string
GetProcessHandle Microsoft.Win32.SafeHandles.SafeProcessHandle
GetProcessHandle Microsoft.Win32.SafeHandles.SafeProcessHandle
GetProcessHandle Microsoft.Win32.SafeHandles.SafeProcessHandle
GetProcessTimes System.Diagnostics.ProcessThreadTimes
GetStat Interop.procfs.ParsedStat
GetWaitState System.Diagnostics.ProcessWaitState
GetWorkingSetLimits void
IsRespondingCore bool
OpenStream System.IO.FileStream
ParseArgumentsIntoList void
ParseArgv string[]
RefreshCore void
ResolvePath string
SetPrivilege void
SetWorkingSetLimitsCore void
Start Process
Start Process
Start System.Diagnostics.Process
Start System.Diagnostics.Process
StartCore bool
TicksToTimeSpan System.TimeSpan
UpdateHasExited void
WaitForExitCore bool
WaitForInputIdleCore bool

공개 메소드들

메소드 설명
BeginErrorReadLine ( ) : void
BeginOutputReadLine ( ) : void
CancelErrorRead ( ) : void
CancelOutputRead ( ) : void
Close ( ) : void
CloseMainWindow ( ) : bool
EnterDebugMode ( ) : void

Puts a Process component in state to interact with operating system processes that run in a special mode by enabling the native property SeDebugPrivilege on the current thread.

GetCurrentProcess ( ) : System.Diagnostics.Process
GetProcessById ( int processId ) : System.Diagnostics.Process
GetProcessById ( int processId, string machineName ) : System.Diagnostics.Process
GetProcesses ( ) : System.Diagnostics.Process[]
GetProcesses ( string machineName ) : System.Diagnostics.Process[]
GetProcessesByName ( string processName, string machineName ) : System.Diagnostics.Process[]

Creates an array of Process components that are associated with process resources on a remote computer. These process resources share the specified process name.

GetProcessesByName ( string processName ) : System.Diagnostics.Process[]
GetProcessesByName ( string processName, string machineName ) : System.Diagnostics.Process[]
Kill ( ) : void

Stops the associated process immediately.

LeaveDebugMode ( ) : void

Takes a Process component out of the state that lets it interact with operating system processes that run in a special mode.

Process ( )
Refresh ( ) : void
Start ( System startInfo ) : System.Diagnostics.Process
Start ( string fileName ) : System.Diagnostics.Process
Start ( string fileName, string arguments ) : System.Diagnostics.Process
Start ( ) : bool
ToString ( ) : string
WaitForExit ( int milliseconds ) : bool
WaitForExit ( ) : void
WaitForInputIdle ( ) : bool
WaitForInputIdle ( int milliseconds ) : bool

보호된 메소드들

메소드 설명
Dispose ( bool disposing ) : void
OnExited ( ) : void

비공개 메소드들

메소드 설명
BootTimeToDateTime ( System.TimeSpan timespanAfterBoot ) : System.DateTime

Computes a time based on a number of ticks since boot.

BuildCommandLine ( string executableFileName, string arguments ) : StringBuilder
CloseCore ( ) : void

Additional logic invoked when the Process is closed.

CloseMainWindowCore ( ) : bool
ConfigureAfterProcessIdSet ( ) : void

Additional configuration when a process ID is set.

CreateEnvp ( ProcessStartInfo psi ) : string[]

Converts the environment variables information from a ProcessStartInfo into an envp array.

CreatePipe ( SafeFileHandle &parentHandle, SafeFileHandle &childHandle, bool parentInputs ) : void
CreatePipeWithSecurityAttributes ( SafeFileHandle &hReadPipe, SafeFileHandle &hWritePipe, Interop &lpPipeAttributes, int nSize ) : void
EnsureHandleCountPopulated ( ) : void
EnvironmentVariablesToByteArray ( string>.Dictionary sd ) : byte[]
GetCurrentProcessId ( ) : int

Gets the ID of the current process.

GetCurrentProcessRUsage ( ) : Interop.libproc.rusage_info_v3
GetEncoding ( int codePage ) : Encoding
GetExePath ( ) : string

Gets the path to the current executable, or null if it could not be retrieved.

GetMainWindowTitle ( ) : string
GetProcessHandle ( ) : SafeProcessHandle

Gets a short-term handle to the process, with the given access. If a handle exists, then it is reused. If the process has exited, it throws an exception.

GetProcessHandle ( int access ) : SafeProcessHandle
GetProcessHandle ( int access, bool throwIfExited ) : SafeProcessHandle
GetProcessTimes ( ) : System.Diagnostics.ProcessThreadTimes

Gets timing information for the current process.

GetStat ( ) : Interop.procfs.ParsedStat

Reads the stats information for this process from the procfs file system.

GetWaitState ( ) : System.Diagnostics.ProcessWaitState

Gets the wait state for this Process object.

GetWorkingSetLimits ( IntPtr &minWorkingSet, IntPtr &maxWorkingSet ) : void

Get the minimum and maximum working set limits.

IsRespondingCore ( ) : bool
OpenStream ( int fd, FileAccess access ) : FileStream

Opens a stream around the specified file descriptor and with the specified access.

ParseArgumentsIntoList ( string arguments, List results ) : void

Parses a command-line argument string into a list of arguments.

This follows the rules outlined in "Parsing C++ Command-Line Arguments" at https://msdn.microsoft.com/en-us/library/17w5ykft.aspx.

ParseArgv ( ProcessStartInfo psi ) : string[]

Converts the filename and arguments information from a ProcessStartInfo into an argv array.

RefreshCore ( ) : void

Discards any information about the associated process.

ResolvePath ( string filename ) : string

Resolves a path to the filename passed to ProcessStartInfo.

SetPrivilege ( string privilegeName, int attrib ) : void
SetWorkingSetLimitsCore ( IntPtr newMin, IntPtr newMax, IntPtr &resultingMin, IntPtr &resultingMax ) : void

Sets one or both of the minimum and maximum working set limits.

Start ( string fileName, string userName, SecureString password, string domain ) : Process
Start ( string fileName, string arguments, string userName, SecureString password, string domain ) : Process
Start ( string fileName, string userName, System password, string domain ) : System.Diagnostics.Process
Start ( string fileName, string arguments, string userName, System password, string domain ) : System.Diagnostics.Process
StartCore ( ProcessStartInfo startInfo ) : bool

Starts the process using the supplied start info.

TicksToTimeSpan ( double ticks ) : System.TimeSpan

Convert a number of "jiffies", or ticks, to a TimeSpan.

UpdateHasExited ( ) : void

Checks whether the process has exited and updates state accordingly.

WaitForExitCore ( int milliseconds ) : bool

Instructs the Process component to wait the specified number of milliseconds for the associated process to exit.

WaitForInputIdleCore ( int milliseconds ) : bool

메소드 상세

BeginErrorReadLine() 공개 메소드

public BeginErrorReadLine ( ) : void
리턴 void

BeginOutputReadLine() 공개 메소드

public BeginOutputReadLine ( ) : void
리턴 void

CancelErrorRead() 공개 메소드

public CancelErrorRead ( ) : void
리턴 void

CancelOutputRead() 공개 메소드

public CancelOutputRead ( ) : void
리턴 void

Close() 공개 메소드

public Close ( ) : void
리턴 void

CloseMainWindow() 공개 메소드

public CloseMainWindow ( ) : bool
리턴 bool

Dispose() 보호된 메소드

protected Dispose ( bool disposing ) : void
disposing bool
리턴 void

EnterDebugMode() 공개 정적인 메소드

Puts a Process component in state to interact with operating system processes that run in a special mode by enabling the native property SeDebugPrivilege on the current thread.
public static EnterDebugMode ( ) : void
리턴 void

GetCurrentProcess() 공개 정적인 메소드

public static GetCurrentProcess ( ) : System.Diagnostics.Process
리턴 System.Diagnostics.Process

GetProcessById() 공개 정적인 메소드

public static GetProcessById ( int processId ) : System.Diagnostics.Process
processId int
리턴 System.Diagnostics.Process

GetProcessById() 공개 정적인 메소드

public static GetProcessById ( int processId, string machineName ) : System.Diagnostics.Process
processId int
machineName string
리턴 System.Diagnostics.Process

GetProcesses() 공개 정적인 메소드

public static GetProcesses ( ) : System.Diagnostics.Process[]
리턴 System.Diagnostics.Process[]

GetProcesses() 공개 정적인 메소드

public static GetProcesses ( string machineName ) : System.Diagnostics.Process[]
machineName string
리턴 System.Diagnostics.Process[]

GetProcessesByName() 공개 정적인 메소드

Creates an array of Process components that are associated with process resources on a remote computer. These process resources share the specified process name.
public static GetProcessesByName ( string processName, string machineName ) : System.Diagnostics.Process[]
processName string
machineName string
리턴 System.Diagnostics.Process[]

GetProcessesByName() 공개 정적인 메소드

public static GetProcessesByName ( string processName ) : System.Diagnostics.Process[]
processName string
리턴 System.Diagnostics.Process[]

GetProcessesByName() 공개 정적인 메소드

public static GetProcessesByName ( string processName, string machineName ) : System.Diagnostics.Process[]
processName string
machineName string
리턴 System.Diagnostics.Process[]

Kill() 공개 메소드

Stops the associated process immediately.
public Kill ( ) : void
리턴 void

LeaveDebugMode() 공개 정적인 메소드

Takes a Process component out of the state that lets it interact with operating system processes that run in a special mode.
public static LeaveDebugMode ( ) : void
리턴 void

OnExited() 보호된 메소드

protected OnExited ( ) : void
리턴 void

Process() 공개 메소드

public Process ( )

Refresh() 공개 메소드

public Refresh ( ) : void
리턴 void

Start() 공개 정적인 메소드

public static Start ( System startInfo ) : System.Diagnostics.Process
startInfo System
리턴 System.Diagnostics.Process

Start() 공개 정적인 메소드

public static Start ( string fileName ) : System.Diagnostics.Process
fileName string
리턴 System.Diagnostics.Process

Start() 공개 정적인 메소드

public static Start ( string fileName, string arguments ) : System.Diagnostics.Process
fileName string
arguments string
리턴 System.Diagnostics.Process

Start() 공개 메소드

public Start ( ) : bool
리턴 bool

ToString() 공개 메소드

public ToString ( ) : string
리턴 string

WaitForExit() 공개 메소드

public WaitForExit ( int milliseconds ) : bool
milliseconds int
리턴 bool

WaitForExit() 공개 메소드

public WaitForExit ( ) : void
리턴 void

WaitForInputIdle() 공개 메소드

public WaitForInputIdle ( ) : bool
리턴 bool

WaitForInputIdle() 공개 메소드

public WaitForInputIdle ( int milliseconds ) : bool
milliseconds int
리턴 bool