pub trait TimeSource: Debug + Send + Sync {
    // Required method
    fn now(&self) -> SystemTime;
}
Expand description

Trait with a now() function returning the current time

Required Methods§

source

fn now(&self) -> SystemTime

Returns the current time

Implementations on Foreign Types§

source§

impl TimeSource for SystemTime

Available on crate feature test-util only.
source§

fn now(&self) -> SystemTime

Implementors§

source§

impl TimeSource for ManualTimeSource

Available on crate feature test-util only.
source§

impl TimeSource for TickAdvanceTime

Available on crate feature test-util only.
source§

impl TimeSource for SharedTimeSource

source§

impl TimeSource for StaticTimeSource

source§

impl TimeSource for SystemTimeSource