Enables communication with a debugger. This class cannot be inherited.
More...
|
| Debugger () |
| Initializes a new instance of the T:System.Diagnostics.Debugger class. More...
|
|
static void | Log (int level, string category, string message) |
| Posts a message for the attached debugger. More...
|
|
static bool | IsLogging () |
| Checks to see if logging is enabled by an attached debugger. More...
|
|
|
static void | Break () |
| Signals a breakpoint to an attached debugger. More...
|
|
static bool | Launch () |
| Launches and attaches a debugger to the process. More...
|
|
static void | NotifyOfCrossThreadDependency () |
| Notifies a debugger that execution is about to enter a path that involves a cross-thread dependency. More...
|
|
|
static bool | IsAttached [get] |
| Gets a value that indicates whether a debugger is attached to the process. More...
|
|
Enables communication with a debugger. This class cannot be inherited.
Definition at line 11 of file Debugger.cs.
◆ Debugger()
System.Diagnostics.Debugger.Debugger |
( |
| ) |
|
Initializes a new instance of the T:System.Diagnostics.Debugger class.
Definition at line 34 of file Debugger.cs.
◆ Break()
static void System.Diagnostics.Debugger.Break |
( |
| ) |
|
|
static |
Signals a breakpoint to an attached debugger.
- Exceptions
-
T:System.Security.SecurityException | The T:System.Security.Permissions.UIPermission is not set to break into the debugger. |
Definition at line 42 of file Debugger.cs.
◆ IsLogging()
static bool System.Diagnostics.Debugger.IsLogging |
( |
| ) |
|
Checks to see if logging is enabled by an attached debugger.
- Returns
true
if a debugger is attached and logging is enabled; otherwise, false
. The attached debugger is the registered managed debugger in the DbgManagedDebugger
registry key. For more information on this key, see Enabling JIT-Attach Debugging.
◆ Launch()
static bool System.Diagnostics.Debugger.Launch |
( |
| ) |
|
|
static |
Launches and attaches a debugger to the process.
- Returns
true
if the startup is successful or if the debugger is already attached; otherwise, false
.
- Exceptions
-
T:System.Security.SecurityException | The T:System.Security.Permissions.UIPermission is not set to start the debugger. |
Definition at line 78 of file Debugger.cs.
◆ Log()
static void System.Diagnostics.Debugger.Log |
( |
int |
level, |
|
|
string |
category, |
|
|
string |
message |
|
) |
| |
Posts a message for the attached debugger.
- Parameters
-
level | A description of the importance of the message. |
category | The category of the message. |
message | The message to show. |
◆ NotifyOfCrossThreadDependency()
static void System.Diagnostics.Debugger.NotifyOfCrossThreadDependency |
( |
| ) |
|
|
static |
Notifies a debugger that execution is about to enter a path that involves a cross-thread dependency.
Definition at line 104 of file Debugger.cs.
◆ DefaultCategory
readonly string System.Diagnostics.Debugger.DefaultCategory |
|
static |
Represents the default category of message with a constant.
Definition at line 18 of file Debugger.cs.
◆ IsAttached
bool System.Diagnostics.Debugger.IsAttached |
|
staticget |
Gets a value that indicates whether a debugger is attached to the process.
- Returns
true
if a debugger is attached; otherwise, false
.
Definition at line 25 of file Debugger.cs.
The documentation for this class was generated from the following file: