Azavea.Open.Common.Chronometer.BeginTiming C# (CSharp) Method

BeginTiming() public static method

Starts timing the specified named operation. Each time the same named operation is completed the time will be added to our list, so that a number of calls to the same command will give you totals, average, and number of executions.
public static BeginTiming ( StringBuilder keyBuilder ) : void
keyBuilder StringBuilder A StringBuilder containing a string that uniquely /// identifies the operation.
return void
        public static void BeginTiming(StringBuilder keyBuilder)
        {
            try
            {
                StringBuilder keyWithThread = _sbCache.Get();
                keyWithThread.Append(keyBuilder);
                keyWithThread.Append(Thread.CurrentThread.Name);
                ReallyBeginTiming(keyWithThread.ToString());
                _sbCache.Return(keyWithThread);
            }
            catch (Exception e)
            {
                _log.Warn("Chronometer failed to begin timing " + keyBuilder, e);
            }
        }

Same methods

Chronometer::BeginTiming ( string key ) : void