|
using System;
using System.Collections.Generic;
using System.Text;
namespace DashboardDataAccess
{
public class TimedLog : IDisposable
{
private string _Message;
private long _StartTicks;
public TimedLog(string userName, string message)
{
this._Message = userName + '\t' + message;
this._StartTicks = DateTime.Now.Ticks;
}
#region IDisposable Members
void IDisposable.Dispose()
{
string msg = this._Message + '\t' + TimeSpan.FromTicks(DateTime.Now.Ticks - this._StartTicks).TotalSeconds.ToString();
//EntLibHelper.PerformanceLog(msg);
System.Diagnostics.Debug.WriteLine(msg);
}
#endregion
}
}
|
By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.
If a file you wish to view isn't highlighted, and is a text file (not binary), please
let us know and we'll add colourisation support for it.