Struct metrix::instruments::other_instruments::LastOccurrenceTracker[][src]

pub struct LastOccurrenceTracker { /* fields omitted */ }

Tracks how many seconds elapsed since the last occurence

Methods

impl LastOccurrenceTracker
[src]

Gets the name of this OccurenceTracker

Set the name if this OccurenceTracker.

The name is a path segment within a Snapshot

Sets the title of this OccurenceTracker.

A title can be part of a descriptive Snapshot

Sets the description of this OccurenceTracker.

A description can be part of a descriptive Snapshot

Set whether the current value should be inverted in a snapshot or not

Default is false

The current value should be inverted in a snapshot

Same as self.set_invert(true);

If set to true possible Nones that would be returned will instead be 0.

Hint: This instrument will return None unless there was at least one Occurence recorded.

return whether make_none_zero is on or off

Returns the current state

Trait Implementations

impl Instrument for LastOccurrenceTracker
[src]

impl PutsSnapshot for LastOccurrenceTracker
[src]

Puts the current snapshot values into the given Snapshot thereby following the guidelines of PutsSnapshot. Read more

impl Updates for LastOccurrenceTracker
[src]

Update the internal state according to the given Update. Read more

impl Descriptive for LastOccurrenceTracker
[src]

Auto Trait Implementations