pub struct TimeLog(pub BTreeMap<Date, Duration>);Expand description
TimeLog capability: a per-day breakdown of time spent, keyed by calendar
date. TimeSpent stays the fast-path cumulative total — it’s recomputed
as this map’s sum whenever it’s set (see the Event::TimeLogSet apply
arm), so aggregation (FR-13) keeps reading TimeSpent unchanged. Mixing
this with the plain AddTimeSpent command (no date) can leave the two
slightly inconsistent — a known, accepted edge case, not guarded against.
Tuple Fields§
§0: BTreeMap<Date, Duration>Trait Implementations§
Source§impl<'de> Deserialize<'de> for TimeLog
impl<'de> Deserialize<'de> for TimeLog
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for TimeLog
impl StructuralPartialEq for TimeLog
Auto Trait Implementations§
impl Freeze for TimeLog
impl RefUnwindSafe for TimeLog
impl Send for TimeLog
impl Sync for TimeLog
impl Unpin for TimeLog
impl UnsafeUnpin for TimeLog
impl UnwindSafe for TimeLog
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more