Skip to main content

SampleCallback

Trait SampleCallback 

Source
pub trait SampleCallback: Send + Sync {
    // Required method
    fn on_sample(&self, sample: ReceivedSample);
}
Expand description

Callback-based sample receiver

Alternative to polling - receive samples via callback.

Required Methods§

Source

fn on_sample(&self, sample: ReceivedSample)

Called when a new sample is received

Implementors§