mouse/src/types/fact.rs
Jochen Maes 71ee0aaab0 improves workings
Signed-off-by: Jochen Maes <jochen@sejo-it.be>
2023-10-27 07:08:18 +02:00

13 lines
263 B
Rust

use std::time::{SystemTime, UNIX_EPOCH};
pub trait Fact: Send + Sync {
fn gather(&self) -> String;
fn get_epoch_ms(&self) -> u128 {
SystemTime::now()
.duration_since(UNIX_EPOCH)
.unwrap()
.as_millis()
}
}