8 个版本
| 0.0.15 | 2024年2月23日 |
|---|---|
| 0.0.14 | 2024年2月23日 |
| 0.0.12 | 2022年11月21日 |
#141 在 日期和时间
40 每月下载
8KB
108 行
temps
temps 或 [tã] 是一个用于在 Rust 中处理日期和时间的库。
使用方法
将 temps 添加到您的 Cargo.toml 文件中。
temps = "0"
hh:mm:ss
由于 hhmmss 已不再维护,我将其功能迁移到了 temps。
let duration = std::time::Duration::new(10, 0); // also works for "chrono::Duration" and "time::Duration"
duration.hhmmss() // yields "00:00:10"
duration.hhmmssxxx() // yields "00:00:10.000"
依赖项
~0–450KB