Crates.io | timelite |
lib.rs | timelite |
version | 1.0.4 |
source | src |
created_at | 2019-10-29 11:52:20.680892 |
updated_at | 2019-10-31 12:11:22.243217 |
description | TimeLite is a simple library to convert days, weeks, months and years into seconds. |
homepage | https://github.com/charleschege/TimeLite |
repository | https://github.com/charleschege/TimeLite |
max_upload_size | |
id | 176624 |
size | 20,272 |
TimeLite is a simple library to convert days, weeks, months and years into seconds.
This library is not necessary if you are using something like chrono
crate but its purpose is to be very ergonomic for users to write seconds on a human level understanding of minutes, hours, days, weeks, months and years.
use timelite::LiteDuration;
let timer = LiteDuration::nanos(100);
use timelite::LiteDuration;
let timer = LiteDuration::micros(1);
use timelite::LiteDuration;
let timer = LiteDuration::millis(1);
use timelite::LiteDuration;
let timer = LiteDuration::seconds(1);
use timelite::LiteDuration;
let timer = LiteDuration::minutes(1);
use timelite::LiteDuration;
let timer = LiteDuration::hours(1);
use timelite::LiteDuration;
let timer = LiteDuration::days(1);
use timelite::LiteDuration;
let timer = LiteDuration::weeks(1);
use timelite::LiteDuration;
let timer = LiteDuration::months(1);
use timelite::LiteDuration;
let timer = LiteDuration::years(1);