Expand description
The clock under one module path: the types under std::time’s names, for signatures that
need one, and every reading, made through now and wall. The UI toolkit and the process
services name the clock through this module and never std::time, so a process whose clock
must be virtualised (a deterministic replay, a test) has one boundary to provide.
Re-exports§
pub use crate::pin_wall;pub use crate::from_std;pub use crate::is_synchronised;pub use crate::local_zone_name;pub use crate::now;pub use crate::to_std;pub use crate::try_unix_now;pub use crate::try_unix_now_ms;pub use crate::try_unix_now_ns;pub use crate::unix_now;pub use crate::unix_now_i64;pub use crate::unix_now_ms;pub use crate::unix_now_ms_i64;pub use crate::unix_now_ns;pub use crate::wall;pub use crate::wall_frozen;pub use crate::from_std as from_file_time;
Structs§
- Duration
- A
Durationtype to represent a span of time, typically used for system timeouts. - Instant
- A measurement of a monotonically nondecreasing clock.
Opaque and useful only with
Duration. - System
Time - A measurement of the system clock, useful for talking to external entities like the file system or other processes.
- System
Time Error - An error returned from the
duration_sinceandelapsedmethods onSystemTime, used to learn how far in the opposite direction a system time lies.
Constants§
- UNIX_
EPOCH - An anchor in time which can be used to create new
SystemTimeinstances or learn about where in time aSystemTimelies.