Skip to main content

ExportResult

Struct ExportResult 

Source
pub struct ExportResult {
    pub command: String,
    pub bench: String,
    pub subject: String,
    pub mean: f64,
    pub stddev: Option<f64>,
    pub median: f64,
    pub min: f64,
    pub max: f64,
    pub times: Vec<f64>,
    pub exit_codes: Vec<i32>,
}

Fields§

§command: String

hyperfine’s display name: the subject, or the benchmark for a single-command one.

§bench: String§subject: String§mean: f64

Seconds, like hyperfine, not the milliseconds tak records.

§stddev: Option<f64>

null for a single sample, as hyperfine writes it.

§median: f64§min: f64§max: f64§times: Vec<f64>

Every timed sample in seconds, in the order taken.

§exit_codes: Vec<i32>

Always zero: a sample that fails drops its subject rather than being kept, so every exported time is from a successful run.

Implementations§

Source§

impl ExportResult

Source

pub fn new( bench: &str, subject: &str, command: &str, samples_ms: &[f64], ) -> Self

Trait Implementations§

Source§

impl Debug for ExportResult

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Serialize for ExportResult

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.