Class DebugUtil
Debug utility provides functions: pause process, count execution time and show the count.
public static class DebugUtil
- Inheritance
-
DebugUtil
- Inherited Members
Properties
Count
public static int Count { get; set; }
Property Value
Data
The data storage for the DebugUtil class.
public static Dictionary<object, object> Data { get; }
Property Value
Debugee
The object being debugged.
public static object Debugee { get; set; }
Property Value
WriteLineAction
The action to be performed when writing a line of text.
public static Action<string> WriteLineAction { get; set; }
Property Value
Methods
C()
Count++.
public static int C()
Returns
- int
current count
CPS(int, string)
public static int CPS(int p = 0, string text = null)
Parameters
Returns
- int
current count
CS(string)
public static int CS(string shownText = null)
Parameters
shownText
stringthe text to show
Returns
- int
count
CSP(int, string)
public static int CSP(int p = 0, string shownText = null)
Parameters
Returns
- int
count
P(int)
Pause if count >= p
.
public static int P(int p = 0)
Parameters
p
intpause number
Returns
- int
current count
S(string)
Call WriteLineAction?.Invoke to show the text and count.
public static int S(string shownText = null)
Parameters
shownText
stringtext to show
Returns
- int
current count
SP(int, string)
public static int SP(int p = 0, string shownText = null)
Parameters
Returns
- int
count
WriteLine(string)
Writes a line of text with the current count. This is an alias for S(string).
public static int WriteLine(string shownText = null)
Parameters
shownText
stringThe text to show.
Returns
- int
The current count.