pub struct Task {
pub title: String,
pub estimate_min: u16,
pub actual_min: u16,
pub actual_carry_sec: u16,
pub started_at_min: Option<u16>,
pub finished_at_min: Option<u16>,
pub sessions: Vec<Session>,
pub state: TaskState,
pub planned_ymd: u32,
pub done_ymd: Option<u32>,
pub category: Category,
pub fixed_start_min: Option<u16>,
}Fields§
§title: String§estimate_min: u16§actual_min: u16§actual_carry_sec: u16Partially accumulated seconds (<60) toward actual_min for this task.
started_at_min: Option<u16>Actual first start time in minutes since local midnight. Recorded when the task first transitions to Active.
finished_at_min: Option<u16>Actual finish time in minutes since local midnight. Recorded when the task is marked Done.
sessions: Vec<Session>Full session log for this task (start/end pairs). The last session
may have end_min=None while the task is Active.
state: TaskState§planned_ymd: u32Planned date for the task (YYYYMMDD). Defaults to today on creation. Used to support date selection on creation and postpone/bring operations.
done_ymd: Option<u32>§category: CategoryUser classification for the task (e.g., Work/Home/Hobby). Defaults to General.
fixed_start_min: Option<u16>Optional fixed planned start time in minutes since local midnight.
When present, the visual schedule uses max(cursor, fixed_start_min) at this task
and pushes the subsequent tasks based on estimates from there.
Implementations§
Source§impl Task
impl Task
pub fn start_session(&mut self, now_min: u16)
pub fn end_session(&mut self, now_min: u16)
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Task
impl<'de> Deserialize<'de> for Task
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>,
impl Eq for Task
impl StructuralPartialEq for Task
Auto Trait Implementations§
impl Freeze for Task
impl RefUnwindSafe for Task
impl Send for Task
impl Sync for Task
impl Unpin for Task
impl UnwindSafe for Task
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more