Trait StoreMetric

Source
pub trait StoreMetric {
    // Required methods
    fn fetch(&self) -> usize;
    fn store(&self, value: usize);
}
Expand description

Used for defining new types of metrics that do not need a counter and act as a persistent indicator.

Required Methods§

Source

fn fetch(&self) -> usize

Returns current value of the counter.

Source

fn store(&self, value: usize)

Stores value to the current counter.

Implementors§