[][src]Struct histo_fp::Histogram

pub struct Histogram { /* fields omitted */ }

A histogram is a collection of samples, sorted into buckets.

See the crate level documentation for more details.

Implementations

impl Histogram[src]

pub fn with_buckets(num_buckets: u64, precision: Option<u32>) -> Histogram[src]

Construct a new histogram with the given number of buckets.

Panics

Panics if the number of buckets is zero.

pub fn add(&mut self, sample: f64)[src]

Add a new float sample to this histogram

pub fn buckets(&self) -> Buckets<'_>

Notable traits for Buckets<'a>

impl<'a> Iterator for Buckets<'a> type Item = Bucket<'a>;
[src]

Get an iterator over this histogram's buckets.

Trait Implementations

impl Clone for Histogram[src]

impl Debug for Histogram[src]

impl Display for Histogram[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,