Trait cadence::ext::ToGaugeValue

source ·
pub trait ToGaugeValue {
    // Required method
    fn try_to_value(self) -> MetricResult<MetricValue>;
}
Expand description

Conversion trait for valid values for gauges

This trait must be implemented for any types that are used as gauge values (currently u64 and f64). This trait is internal to how values are formatted as part of metrics but is exposed publicly for documentation purposes.

Typical use of Cadence shouldn’t require interacting with this trait.

Required Methods§

Implementations on Foreign Types§

source§

impl ToGaugeValue for f64

source§

impl ToGaugeValue for u64

Implementors§