Trait zng_unit::TimeUnits

source ·
pub trait TimeUnits {
    // Required methods
    fn ms(self) -> Duration;
    fn secs(self) -> Duration;
    fn minutes(self) -> Duration;
    fn hours(self) -> Duration;
}
Expand description

Extension methods for initializing Duration values.

Required Methods§

source

fn ms(self) -> Duration

Milliseconds.

source

fn secs(self) -> Duration

Seconds.

source

fn minutes(self) -> Duration

Minutes.

source

fn hours(self) -> Duration

Hours.

Implementations on Foreign Types§

source§

impl TimeUnits for f32

source§

impl TimeUnits for u64

Implementors§