这个方法不知道拿来干什么的
public static void CheckCondition(bool condition, String errorText, int lineNumber)
{
//Test the condition
if ( !condition )
{
//Assert and throw if the condition is not met
String detailMessage;
GenerateStackTrace(lineNumber, out detailMessage);
Debug.Fail(errorText, detailMessage);
        
throw new ApplicationException(errorText);
            
}
}public static int LineNumber
{
get
{
try
{
//
// Get the trace information with file information by skipping
//   this function and then reading the top stack frame.
//
return (new StackTrace(1, true)).GetFrame(0).GetFileLineNumber();
}
catch
{
} return 0;
}
}