Trait Clock

Source
pub trait Clock: Send + Sync {
    // Required methods
    fn now(&self) -> Timestamp;
    fn clone_box(&self) -> Box<dyn Clock>;
}
Expand description

A trait for providing the current time.

Required Methods§

Source

fn now(&self) -> Timestamp

Source

fn clone_box(&self) -> Box<dyn Clock>

Implementors§