mscorlib(4.0.0.0) API with additions
|
Provides a set of methods and properties that help debug your code. More...
Static Public Member Functions | |
static void | Flush () |
Flushes the output buffer and causes buffered data to write to the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Close () |
Flushes the output buffer and then calls the Close method on each of the P:System.Diagnostics.Debug.Listeners. More... | |
static void | Assert (bool condition) |
Checks for a condition; if the condition is false , displays a message box that shows the call stack. More... | |
static void | Assert (bool condition, string message) |
Checks for a condition; if the condition is false , outputs a specified message and displays a message box that shows the call stack. More... | |
static void | Assert (bool condition, string message, string detailMessage) |
Checks for a condition; if the condition is false , outputs two specified messages and displays a message box that shows the call stack. More... | |
static void | Assert (bool condition, string message, string detailMessageFormat, params object[] args) |
Checks for a condition; if the condition is false , outputs two messages (simple and formatted) and displays a message box that shows the call stack. More... | |
static void | Fail (string message) |
Emits the specified error message. More... | |
static void | Fail (string message, string detailMessage) |
Emits an error message and a detailed error message. More... | |
static void | Print (string message) |
Writes a message followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Print (string format, params object[] args) |
Writes a formatted string followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Write (string message) |
Writes a message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Write (object value) |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Write (string message, string category) |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | Write (object value, string category) |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteLine (string message) |
Writes a message followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteLine (object value) |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteLine (string message, string category) |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteLine (object value, string category) |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteLine (string format, params object[] args) |
Writes a formatted message followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection. More... | |
static void | WriteIf (bool condition, string message) |
Writes a message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteIf (bool condition, object value) |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteIf (bool condition, string message, string category) |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteIf (bool condition, object value, string category) |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteLineIf (bool condition, string message) |
Writes a message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteLineIf (bool condition, object value) |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteLineIf (bool condition, string message, string category) |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | WriteLineIf (bool condition, object value, string category) |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true . More... | |
static void | Indent () |
Increases the current P:System.Diagnostics.Debug.IndentLevel by one. More... | |
static void | Unindent () |
Decreases the current P:System.Diagnostics.Debug.IndentLevel by one. More... | |
Properties | |
static TraceListenerCollection | Listeners [get] |
Gets the collection of listeners that is monitoring the debug output. More... | |
static bool | AutoFlush [get, set] |
Gets or sets a value indicating whether M:System.Diagnostics.Debug.Flush should be called on the P:System.Diagnostics.Debug.Listeners after every write. More... | |
static int | IndentLevel [get, set] |
Gets or sets the indent level. More... | |
static int | IndentSize [get, set] |
Gets or sets the number of spaces in an indent. More... | |
Provides a set of methods and properties that help debug your code.
|
static |
|
static |
Checks for a condition; if the condition is false
, outputs a specified message and displays a message box that shows the call stack.
condition | The conditional expression to evaluate. If the condition is true , the specified message is not sent and the message box is not displayed. |
message | The message to send to the P:System.Diagnostics.Trace.Listeners collection. |
|
static |
Checks for a condition; if the condition is false
, outputs two specified messages and displays a message box that shows the call stack.
condition | The conditional expression to evaluate. If the condition is true , the specified messages are not sent and the message box is not displayed. |
message | The message to send to the P:System.Diagnostics.Trace.Listeners collection. |
detailMessage | The detailed message to send to the P:System.Diagnostics.Trace.Listeners collection. |
|
static |
Checks for a condition; if the condition is false
, outputs two messages (simple and formatted) and displays a message box that shows the call stack.
condition | The conditional expression to evaluate. If the condition is true , the specified messages are not sent and the message box is not displayed. |
message | The message to send to the P:System.Diagnostics.Trace.Listeners collection. |
detailMessageFormat | The composite format string (see Remarks) to send to the P:System.Diagnostics.Trace.Listeners collection. This message contains text intermixed with zero or more format items, which correspond to objects in the args array. |
args | An object array that contains zero or more objects to format. |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
Writes a formatted string followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection.
format | A composite format string (see Remarks) that contains text intermixed with zero or more format items, which correspond to objects in the args array. |
args | An object array containing zero or more objects to format. |
T:System.ArgumentNullException | format is null . |
T:System.FormatException | format is invalid.-or- The number that indicates an argument to format is less than zero, or greater than or equal to the number of specified objects to format. |
|
static |
|
static |
|
static |
|
static |
|
static |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection.
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
category | A category name used to organize the output. |
|
static |
Writes a message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the message is written to the trace listeners in the collection. |
message | A message to write. |
|
static |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the value is written to the trace listeners in the collection. |
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
|
static |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the category name and message are written to the trace listeners in the collection. |
message | A message to write. |
category | A category name used to organize the output. |
|
static |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the category name and value are written to the trace listeners in the collection. |
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
category | A category name used to organize the output. |
|
static |
|
static |
|
static |
|
static |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection.
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
category | A category name used to organize the output. |
|
static |
Writes a formatted message followed by a line terminator to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection.
format | A composite format string (see Remarks) that contains text intermixed with zero or more format items, which correspond to objects in the args array. |
args | An object array that contains zero or more objects to format. |
|
static |
Writes a message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the message is written to the trace listeners in the collection. |
message | A message to write. |
|
static |
Writes the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the value is written to the trace listeners in the collection. |
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
|
static |
Writes a category name and message to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | true to cause a message to be written; otherwise, false . |
message | A message to write. |
category | A category name used to organize the output. |
|
static |
Writes a category name and the value of the object's M:System.Object.ToString method to the trace listeners in the P:System.Diagnostics.Debug.Listeners collection if a condition is true
.
condition | The conditional expression to evaluate. If the condition is true , the category name and value are written to the trace listeners in the collection. |
value | An object whose name is sent to the P:System.Diagnostics.Debug.Listeners. |
category | A category name used to organize the output. |
|
staticgetset |
Gets or sets a value indicating whether M:System.Diagnostics.Debug.Flush should be called on the P:System.Diagnostics.Debug.Listeners after every write.
true
if M:System.Diagnostics.Debug.Flush is called on the P:System.Diagnostics.Debug.Listeners after every write; otherwise, false
.
|
staticgetset |
|
staticgetset |
|
staticget |