Struct libcantal::Integer
[−]
[src]
pub struct Integer { /* fields omitted */ }
A kind of metric (Value
) that exports gauge with integer value
Methods
impl Integer
[src]
fn new() -> Integer
[src]
Create a new integer gauge value
Note you need to export it in a collection to make it visible for cantal agent
fn incr(&self, val: i64)
[src]
Increase the value of a gauge
fn decr(&self, val: i64)
[src]
Decrease the value of a gauge
fn set(&self, val: i64)
[src]
Set (replace) the value of a gauge
fn get(&self) -> i64
[src]
Get current value of a gauge
Note it works regardless of whether it's attached to a value
Trait Implementations
impl Display for Integer
[src]
fn fmt(&self, fmt: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more