Sha256: 54c8255af52a5806486e7b7e8addd2341836d025c3f8e8cd6d9373447319c33b
Contents?: true
Size: 560 Bytes
Versions: 6
Compression:
Stored size: 560 Bytes
Contents
use cap_std::time::{Duration, Instant, SystemTime}; pub enum SystemTimeSpec { SymbolicNow, Absolute(SystemTime), } pub trait WasiSystemClock: Send + Sync { fn resolution(&self) -> Duration; fn now(&self, precision: Duration) -> SystemTime; } pub trait WasiMonotonicClock: Send + Sync { fn resolution(&self) -> Duration; fn now(&self, precision: Duration) -> Instant; } pub struct WasiClocks { pub system: Box<dyn WasiSystemClock>, pub monotonic: Box<dyn WasiMonotonicClock>, pub creation_time: cap_std::time::Instant, }
Version data entries
6 entries across 6 versions & 1 rubygems