Module time
Available on crate feature
dep_rustix
only.Expand description
Time-related operations.
Structs§
- Timerfd
Flags TFD_*
flags for use withtimerfd_create
.- Timerfd
Timer Flags TFD_TIMER_*
flags for use withtimerfd_settime
.
Enums§
- ClockId
CLOCK_*
constants for use withclock_gettime
.- Dynamic
Clock Id CLOCK_*
constants for use withclock_gettime_dynamic
.- Timerfd
Clock Id CLOCK_*
constants for use withtimerfd_create
.
Functions§
- clock_
getres clock_getres(id)
—Returns the resolution of a clock.- clock_
gettime clock_gettime(id)
—Returns the current value of a clock.- clock_
gettime_ dynamic - Like
clock_gettime
but with support for dynamic clocks. - clock_
settime clock_settime(id, timespec)
—Sets the current value of a settable clock.- timerfd_
create timerfd_create(clockid, flags)
—Create a timer.- timerfd_
gettime timerfd_gettime(clockid, flags)
—Query a timer.- timerfd_
settime timerfd_settime(clockid, flags, new_value)
—Set the time on a timer.
Type Aliases§
- Itimerspec
struct itimerspec
for use withtimerfd_gettime
andtimerfd_settime
.- Nsecs
- A type for the
tv_sec
field ofTimespec
. - Secs
- A type for the
tv_sec
field ofTimespec
. - Timespec
struct timespec