Example #1
0
 private static IMetric GetOrRegisterMetric(string entry)
 {
     var metric = MetricRepository.GetByName(entry);
     if (metric == null)
     {
         metric = new InMemoryMetric(entry);
         MetricRepository.Save(metric);
     }
     return metric;
 }
Example #2
0
        private static IMetric GetOrRegisterMetric(string entry)
        {
            var metric = MetricRepository.GetByName(entry);

            if (metric == null)
            {
                metric = new InMemoryMetric(entry);
                MetricRepository.Save(metric);
            }
            return(metric);
        }