Method | Description | |
---|---|---|
Attach ( IDebugEventCallback2 pCallback, System.Guid rgguidSpecificEngines, uint celtSpecificEngines, int rghrEngineAttach ) : int |
Attaches the session debug manager (SDM) to the process. Attaching to a process attaches the SDM to all programs running in that process that can be debugged by the debug engines (DE) specified in the rgguidSpecificEngines array. Set the rgguidSpecificEngines parameter to a null value or include GUID_NULL in the array to attach to all programs in the process. All debug events that occur in the process are sent to the given IDebugEventCallback2 object. This IDebugEventCallback2 object is provided when the SDM calls this method. |
|
CanDetach ( ) : int |
Determines if the session debug manager (SDM) can detach the process.
|
|
CauseBreak ( ) : int |
Requests that the next program that is running code in this process halt and send an IDebugBreakEvent2 event object.
|
|
Continue ( IDebugThread2 pThread ) : int |
Continues running this process from a stopped state. Any previous execution state (such as a step) is preserved, and the process starts executing again. ** This method should be used instead of IDebugProgram2::Continue. This method is called on this process regardless of how many processes are being debugged, or which process generated the stopping event. The implementation must retain the previous execution state (such as a step) and continue execution as though it had never stopped before completing its prior execution. That is, if a thread in this process was doing a step-over operation and was stopped because some other process stopped, and then Continue was called, the specified thread must complete the original step-over operation. Warning Do not send a stopping event or an immediate (synchronous) event to IDebugEventCallback2::Event while handling this call; otherwise the debugger might stop responding. |
|
Detach ( ) : int |
Detaches the debugger from this process by detaching all of the programs in the process. All programs and the process continue running, but are no longer part of the debug session. After the detach operation is complete, no more debug events for this process (and its programs) will be sent. |
|
DisableENC ( EncUnavailableReason reason ) : int |
This method explicitly disables Edit and Continue on this process (and all programs it contains). A custom port supplier should always return E_NOTIMPL. A custom port supplier should always return E_NOTIMPL. Once Edit and Continue is disabled for a process, it can be re-enabled only by restarting the process. |
|
EnumPrograms ( IEnumDebugPrograms2 &ppEnum ) : int |
Retrieves a list of all the programs contained by this process.
|
|
EnumThreads ( IEnumDebugThreads2 &ppEnum ) : int |
Retrieves a list of all the threads running in the process. This method enumerates the threads running in each program and then combines them into a process view of the threads. A single thread may run in multiple programs; this method enumerates that thread only once. This method presents a list of the process's threads without duplicates. Otherwise, to enumerate the threads running in a particular program, use the IDebugProgram2::EnumThreads method. |
|
Execute ( IDebugThread2 pThread ) : int |
Continues running this process from a stopped state. Any previous execution state (such as a step) is cleared and the process starts executing again. ** This method should be used instead of IDebugProgram2::Execute. When the user starts execution from a stopped state in some other process's thread, this method is called on this process. This method is also called when the user selects the Start command from the Debug menu in the IDE. The implementation of this method may be as simple as calling the IDebugThread2::Resume method on the current thread in the process. Warning: Do not send a stopping event or an immediate (synchronous) event to IDebugEventCallback2::Event while handling this call; otherwise the debugger might stop responding. |
|
GetDebugReason ( enum_DEBUG_REASON pReason ) : int |
This method returns the reason that the process was launched for debugging.
|
|
GetENCAvailableState ( EncUnavailableReason pReason ) : int |
This method gets the current Edit and Continue state of the process. A custom port supplier should always return E_NOTIMPL. A custom port supplier should always return E_NOTIMPL. This state can be affected by IDebugProcess3::DisableENC. |
|
GetEngineFilter ( GUID_ARRAY pEngineArray ) : int |
Retrieves an array of unique identifiers for available debug engines.
|
|
GetHostingProcessLanguage ( System.Guid &pguidLang ) : int |
This method returns a GUID representing the language of this process as set by a call to IDebugProcess3::SetHostingProcessLanguage.
|
|
GetInfo ( enum_PROCESS_INFO_FIELDS Fields, PROCESS_INFO pProcessInfo ) : int |
Gets a description of the process.
|
|
GetName ( enum_GETNAME_TYPE gnType, string &pbstrName ) : int |
Gets the title, friendly name, or file name of the process.
|
|
GetPhysicalProcessId ( AD_PROCESS_ID pProcessId ) : int |
Gets the system process identifier.
|
|
GetPort ( IDebugPort2 &ppPort ) : int |
Gets the port that the process is running on.
|
|
GetProcessId ( System.Guid &pguidProcessId ) : int |
Gets the GUID for this process. The Globally Unique IDentifier (GUID) identifies this process from all other processes running in the system. |
|
GetServer ( IDebugCoreServer2 &ppServer ) : int |
Gets the server that this process is running on. More than one server can be running on a single machine. |
|
SetHostingProcessLanguage ( System.Guid &guidLang ) : int |
This method sets the language that the process will be hosted under. This language can then be used by the debug engine (DE) to load the appropriate expression evaluator. IDebugProcess3::GetHostingProcessLanguage can be used to retrieve the current language setting. |
|
Step ( IDebugThread2 pThread, enum_STEPKIND sk, enum_STEPUNIT Step ) : int |
Causes the process to step one instruction or statement. ** This method should be used instead of IDebugProgram2::Step. In case there is any thread synchronization or communication between threads, other threads in the process should run when a particular thread is stepping. Warning Do not send a stopping event or an immediate (synchronous) event to IDebugEventCallback2::Event while handling this call; otherwise the debugger might stop responding. |
|
Terminate ( ) : int |
Terminates the process. When a process is terminated, all programs within that process are terminated; none are allowed to run any more code. |
Method | Description | |
---|---|---|
GetAttachedSessionName ( string &pbstrSessionName ) : int |
public Attach ( IDebugEventCallback2 pCallback, System.Guid rgguidSpecificEngines, uint celtSpecificEngines, int rghrEngineAttach ) : int | ||
pCallback | IDebugEventCallback2 | An IDebugEventCallback2 object that is used for debug event notification. |
rgguidSpecificEngines | System.Guid | An array of GUIDs of debug engines to be used to debug programs running in the process. This parameter can be a null value. See Remarks for details. |
celtSpecificEngines | uint | The number of debug engines in the rgguidSpecificEngines array and the size of the rghrEngineAttach array. |
rghrEngineAttach | int | An array of HRESULT codes returned by the debug engines. The size of this array is specified in the celtSpecificEngines parameter. Each code is typically either S_OK or S_ATTACH_DEFERRED. The latter indicates that the DE is currently attached to no programs. |
return | int |
public Continue ( IDebugThread2 pThread ) : int | ||
pThread | IDebugThread2 | An IDebugThread2 object representing the thread to be continued. |
return | int |
public DisableENC ( EncUnavailableReason reason ) : int | ||
reason | EncUnavailableReason | A value from the EncUnavailableReason enumeration. |
return | int |
public EnumPrograms ( IEnumDebugPrograms2 &ppEnum ) : int | ||
ppEnum | IEnumDebugPrograms2 | Returns an IEnumDebugPrograms2 object that contains a list of all the programs in the process. |
return | int |
public EnumThreads ( IEnumDebugThreads2 &ppEnum ) : int | ||
ppEnum | IEnumDebugThreads2 | Returns an IEnumDebugThreads2 object that contains a list of all threads in all programs in the process. |
return | int |
public Execute ( IDebugThread2 pThread ) : int | ||
pThread | IDebugThread2 | An IDebugThread2 object representing the thread to execute. |
return | int |
public GetDebugReason ( enum_DEBUG_REASON pReason ) : int | ||
pReason | enum_DEBUG_REASON | Returns a value from the DEBUG_REASON enumeration. |
return | int |
public GetENCAvailableState ( EncUnavailableReason pReason ) : int | ||
pReason | EncUnavailableReason | A value from the EncUnavailableReason enumeration. |
return | int |
public GetEngineFilter ( GUID_ARRAY pEngineArray ) : int | ||
pEngineArray | GUID_ARRAY | Reference to a structure that contains unique identifiers for debug engines. |
return | int |
public GetHostingProcessLanguage ( System.Guid &pguidLang ) : int | ||
pguidLang | System.Guid | The GUID of the language of this process. GUID_NULL (C++) or Guid.Empty (C#) means that the language is not set. |
return | int |
public GetInfo ( enum_PROCESS_INFO_FIELDS Fields, PROCESS_INFO pProcessInfo ) : int | ||
Fields | enum_PROCESS_INFO_FIELDS | A combination of values from the PROCESS_INFO_FIELDS enumeration that specifies which fields of the pProcessInfo parameter are to be filled in. |
pProcessInfo | PROCESS_INFO | A PROCESS_INFO structure that is filled in with a description of the process. |
return | int |
public GetName ( enum_GETNAME_TYPE gnType, string &pbstrName ) : int | ||
gnType | enum_GETNAME_TYPE | A value from the GETNAME_TYPE enumeration that specifies what type of name to return. |
pbstrName | string | Returns the name of the process. |
return | int |
public GetPhysicalProcessId ( AD_PROCESS_ID pProcessId ) : int | ||
pProcessId | AD_PROCESS_ID | |
return | int |
public GetPort ( IDebugPort2 &ppPort ) : int | ||
ppPort | IDebugPort2 | Returns an IDebugPort2 object that represents the port on which the process was launched. |
return | int |
public GetProcessId ( System.Guid &pguidProcessId ) : int | ||
pguidProcessId | System.Guid | Returns the GUID for this process. |
return | int |
public GetServer ( IDebugCoreServer2 &ppServer ) : int | ||
ppServer | IDebugCoreServer2 | Returns an IDebugCoreServer2 object that represents the server on which this process is running. |
return | int |
public SetHostingProcessLanguage ( System.Guid &guidLang ) : int | ||
guidLang | System.Guid | GUID of the language that the DE should use. Specify GUID_NULL (C++) or Guid.Empty (C#) to have the DE use the default language. |
return | int |
public Step ( IDebugThread2 pThread, enum_STEPKIND sk, enum_STEPUNIT Step ) : int | ||
pThread | IDebugThread2 | An IDebugThread2 object representing the thread being stepped. |
sk | enum_STEPKIND | One of the STEPKIND values. |
Step | enum_STEPUNIT | One of the STEPUNIT values. |
return | int |