Metric constructor
const
Metric(})
Implementation
const Metric(
String _name,
this.type,
this.value, {
this.host,
this.interval,
this.prefix,
this.tags,
}) : assert(
type != MetricType.gauge || interval == null,
'`interval` is only applicable for `count` and `rate`',
),
name = prefix == null ? _name : '$prefix.$_name';