Struct libreda_db::profile::PerfCounter
source · [−]Expand description
Statistics on calls of a single function.
Fields
num_calls: usize
Number of function calls.
total_time: Duration
Total time spent in this function.
Implementations
sourceimpl PerfCounter
impl PerfCounter
sourcefn start_measurement(&mut self) -> PerfCounterManager<'_>
fn start_measurement(&mut self) -> PerfCounterManager<'_>
Start measuring the spent time.
Must call stop()
on the return value.
Trait Implementations
sourceimpl Clone for PerfCounter
impl Clone for PerfCounter
sourcefn clone(&self) -> PerfCounter
fn clone(&self) -> PerfCounter
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for PerfCounter
impl Debug for PerfCounter
sourceimpl Default for PerfCounter
impl Default for PerfCounter
sourcefn default() -> PerfCounter
fn default() -> PerfCounter
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for PerfCounter
impl Send for PerfCounter
impl Sync for PerfCounter
impl Unpin for PerfCounter
impl UnwindSafe for PerfCounter
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more