##// END OF EJS Templates
working version of the project
cin -
r200:71e543dbe65a v2
parent child
Show More
@@ -48,7 +48,7 namespace Implab.Diagnostics {
48 48 }
49 49
50 50 public void StartLogicalOperation(string name) {
51 LogChannel<TraceEvent>.Default.LogEvent(new TraceEvent(TraceEventType.OperationStarted, name));
51 LogChannel<TraceEvent>.Default.LogEvent(new TraceEvent(TraceContext.Instance.CurrentOperation, TraceEventType.OperationStarted, name));
52 52 m_current.BeginLogicalOperation(name);
53 53 }
54 54
@@ -34,7 +34,7 namespace Implab.Diagnostics {
34 34 [Conditional("TRACE")]
35 35 public static void EndLogicalOperation() {
36 36 var op = TraceContext.Instance.EndLogicalOperation();
37 LogChannel<TraceEvent>.Default.LogEvent(new TraceEvent(TraceEventType.OperationCompleted, String.Format("-{0} : {1}ms",op.Name, op.Duration)));
37 LogChannel<TraceEvent>.Default.LogEvent(new TraceEvent(op, TraceEventType.OperationCompleted, String.Format("-{0} : {1}ms",op.Name, op.Duration)));
38 38 }
39 39
40 40 /// <summary>
@@ -44,7 +44,7 namespace Implab.Diagnostics {
44 44 /// <param name="arguments">Arguments.</param>
45 45 [Conditional("TRACE")]
46 46 public static void TraceInformation(string format, params object[] arguments) {
47 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceEventType.Information, format, arguments));
47 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceContext.Instance.CurrentOperation, TraceEventType.Information, format, arguments));
48 48 }
49 49
50 50 /// <summary>
@@ -54,12 +54,12 namespace Implab.Diagnostics {
54 54 /// <param name="arguments">Arguments.</param>
55 55 [Conditional("TRACE")]
56 56 public static void TraceWarning(string format, params object[] arguments) {
57 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceEventType.Warning, format, arguments));
57 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceContext.Instance.CurrentOperation, TraceEventType.Warning, format, arguments));
58 58 }
59 59
60 60 [Conditional("TRACE")]
61 61 public static void TraceError(string format, params object[] arguments) {
62 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceEventType.Error, format, arguments));
62 LogChannel<TraceEvent>.Default.LogEvent(TraceEvent.Create(TraceContext.Instance.CurrentOperation, TraceEventType.Error, format, arguments));
63 63 }
64 64
65 65 [Conditional("TRACE")]
General Comments 3
Under Review
author

Auto status change to "Under Review"

Approved
author

ok, latest stable version should be in default

You need to be logged in to leave comments. Login now