std.time
Types
struct DateTime
struct Duration
struct Instant
struct InvalidDateTimeError
struct ParseTimeError
struct Ticker
struct TimeZone
Functions
local_offset
pub fn local_offset(): int
Return the current local time offset in seconds.
local_offset
pub fn local_offset(): int
Return the current local time offset in seconds.
Return the current local time offset in seconds.
Sleep for the given amount of time.
This will blocking the program until the time is up.
Sleep for the given amount of time. This will blocking the program until the time is up.
Sleep for the given amount of time. This will blocking the program until the time is up.
The duration
is a std.time.Duration
type.
nv,
use std.time;
time.sleep(0.01.seconds()); // Sleep 0.01 seconds