wall-clock

Crates.iowall-clock
lib.rswall-clock
version0.2.2
sourcesrc
created_at2024-04-02 00:11:18.501064
updated_at2024-04-03 22:47:22.645095
descriptionA representation of time as displayed on a wall clock, without date or time zone.
homepage
repositoryhttps://github.com/lukesneeringer/wall-clock
max_upload_size
id1193067
size12,914
Luke Sneeringer (lukesneeringer)

documentation

https://docs.rs/wall_clock

README

Wall Clock Time

ci codecov release docs

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 desearialization with serde. (Enabled by default.)
Commit count: 6

cargo fmt