pub trait Now { // Required method fn now(&self) -> Date<Local>; }
Trait providing a now function.
now
The use of a trait instead of calling directly Local::now is needed in order to be able to mock time in tests
Local::now
Returns current local time