pub trait Metric: Debug {
// Required methods
fn type(&self) -> MetricType;
fn value(&self) -> MetricValue;
fn as_any(&self) -> &dyn Any;
}
Expand description
Trait for metric items.
Required Methods§
Sourcefn type(&self) -> MetricType
fn type(&self) -> MetricType
Returns the type of this metric.
Sourcefn value(&self) -> MetricValue
fn value(&self) -> MetricValue
Returns the current value of this metric.