Expand description
wall-clock
provides a simple and very basic struct for repsenting time as one reads it off a
clock on the wall, e.g. with no concept of date, or time zone.
§Examples
Making a wall clock time:
use wall_clock::WallClockTime;
let wct = WallClockTime::new(15, 0, 0);
You can also use the time!
macro to get a syntax resembling a literal:
use wall_clock::time;
let wct = time!(15:00:00);
§Features
wall-clock
ships with the following features:
- diesel-pg: Enables interop with PostgreSQL
TIME
columns using Diesel. - serde: Enables serialization and deserialization with
serde
. (Enabled by default.)
Macros§
- time
- Construct a wall clock time from a
HH:MM:SS
literal.
Structs§
- Wall
Clock Time - A representation of a time, as read from a wall clock, independent of date or time zone.