Beispiel #1
0
 /// <summary>
 /// 性能计数结束
 /// <remarks>性能计数本身会消耗性能,在想统计性能的方法段的开始调用该方法,在末尾调用PerformanceStop()方法可输出日志,两者必须匹配</remarks>
 /// </summary>
 public static void PerformanceStop(object key)
 {
     if (key != null && !string.IsNullOrEmpty(key.ToString()))
     {
         PerformanceHelper.StopPerformance(key.ToString());
     }
 }
Beispiel #2
0
 /// <summary>
 /// 性能计数结束
 /// <remarks>性能计数本身会消耗性能,在想统计性能的方法段的开始调用该方法,在末尾调用PerformanceStop()方法可输出日志,两者必须匹配</remarks>
 /// </summary>
 public static void PerformanceStop([CallerFilePath] string filePath = "", [CallerMemberName] string methodName = "")
 {
     PerformanceHelper.StopPerformance(filePath, methodName);
 }