pub struct PulseTracer { /* private fields */ }Expand description
Sends metrics as pulse that can change value to any.
Implementations§
Source§impl PulseTracer
impl PulseTracer
Sourcepub fn inc(&self, delta: f64, timestamp: Option<SystemTime>)
pub fn inc(&self, delta: f64, timestamp: Option<SystemTime>)
Increments the value by the specific delta.
Sourcepub fn dec(&self, delta: f64, timestamp: Option<SystemTime>)
pub fn dec(&self, delta: f64, timestamp: Option<SystemTime>)
Decrements the value by the specific delta.
Sourcepub fn set(&self, new_value: f64, timestamp: Option<SystemTime>)
pub fn set(&self, new_value: f64, timestamp: Option<SystemTime>)
Set the value.
Methods from Deref<Target = Tracer<PulseState>>§
Sourcepub fn send(
&self,
data: <T as Flow>::Event,
opt_system_time: Option<SystemTime>,
direction: Option<Direction<ProviderProtocol>>,
)
pub fn send( &self, data: <T as Flow>::Event, opt_system_time: Option<SystemTime>, direction: Option<Direction<ProviderProtocol>>, )
Send an event to a Recorder.
Sourcepub fn subscribe(&mut self) -> Result<Receiver<ActionEnvelope<T>>, Error>
pub fn subscribe(&mut self) -> Result<Receiver<ActionEnvelope<T>>, Error>
Subscribe to the stream of the watcher.
Trait Implementations§
Source§impl Clone for PulseTracer
impl Clone for PulseTracer
Source§fn clone(&self) -> PulseTracer
fn clone(&self) -> PulseTracer
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PulseTracer
impl Debug for PulseTracer
Source§impl Deref for PulseTracer
impl Deref for PulseTracer
Auto Trait Implementations§
impl Freeze for PulseTracer
impl !RefUnwindSafe for PulseTracer
impl Send for PulseTracer
impl Sync for PulseTracer
impl Unpin for PulseTracer
impl !UnwindSafe for PulseTracer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more