Type Alias zx::BootInstant

source ·
pub type BootInstant = Instant<BootTimeline>;
Expand description

A timestamp from the boot clock. Advances while the system is suspended.

Aliased Type§

struct BootInstant(/* private fields */);

Implementations§

source§

impl BootInstant

source

pub fn get() -> Self

Get the current boot time which advances during system suspend.

WARNING: this has been added in advance of https://fxrev.dev/1066674, the boot timeline is not yet available in the stable vdso. This currently uses the monotonic clock which is temporarily equivalent to the boot clock until the monotonic clock starts pausing during suspend in the near future. This will be migrated to the boot clock before the monotonic clock begins pausing during suspend.

source

pub fn after(duration: Duration) -> Self

Compute a deadline for the time in the future that is the given Duration away.