コード例 #1
0
 public StatsdService(IList<IBackend> backends, StatsdServiceConfig config = null)
 {
     _backends = backends;
     _handlers.Add(MetricTypeContants.Counter, HandleCounter);
     _handlers.Add(MetricTypeContants.Gauge, HandleGauge);
     _handlers.Add(MetricTypeContants.Set, HandleSet);
     _handlers.Add(MetricTypeContants.Timer, HandleTimer);
     _activeSnapshot = new ActiveSnapshot();
     _config = config ?? new StatsdServiceConfig();
 }
コード例 #2
0
 public IStatsdServiceBuilder UseConfig(StatsdServiceConfig config)
 {
     _config = config;
     return this;
 }