Struct climer::timer::TimerBuilder
source · pub struct TimerBuilder { /* private fields */ }
Expand description
The builder struct for Timer
.
Implementations§
source§impl TimerBuilder
impl TimerBuilder
sourcepub fn start_time(self, start_time: Time) -> Self
pub fn start_time(self, start_time: Time) -> Self
Set the start_time
Time
.
sourcepub fn format<T>(self, format: T) -> Selfwhere
T: ToString,
pub fn format<T>(self, format: T) -> Selfwhere T: ToString,
TODO: Unimplemented
Set the format
string, used for parsing the given time string.
sourcepub fn print_interval(self, print_interval: Time) -> Self
pub fn print_interval(self, print_interval: Time) -> Self
Set the interval in which output should be printed to stdout.
sourcepub fn write<T>(self, write: T) -> Selfwhere
T: ToString,
pub fn write<T>(self, write: T) -> Selfwhere T: ToString,
Set a file for the output to be written to, instead of stdout.
sourcepub fn continue_after_finish(self, continue_after_finish: bool) -> Self
pub fn continue_after_finish(self, continue_after_finish: bool) -> Self
Specify if timer should continue timing into negative time after it finishes.
sourcepub fn build(self) -> ClimerResult<Timer>
pub fn build(self) -> ClimerResult<Timer>
Build a Timer
.
Trait Implementations§
source§impl Default for TimerBuilder
impl Default for TimerBuilder
source§fn default() -> TimerBuilder
fn default() -> TimerBuilder
Returns the “default value” for a type. Read more