pub struct DailyChart<'a>(/* private fields */);Expand description
Representation of chart report about a Day.
Implementations§
Source§impl<'a> DailyChart<'a>
impl<'a> DailyChart<'a>
Sourcepub fn project_percentages(&self) -> Percentages
pub fn project_percentages(&self) -> Percentages
Return a Vec of tuples mapping project name to percentage of the overall
time this project took.
Sourcepub fn task_percentages(&self, proj: &str) -> Percentages
pub fn task_percentages(&self, proj: &str) -> Percentages
Return a Vec of tuples mapping the task name and percentage of the
supplied project.
Sourcepub fn project_pie<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
pub fn project_pie<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
Write a pie chart representing the projects for the current day to the supplied
EventWriter.
§Errors
Could return any formatting error
Sourcepub fn project_hours<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
pub fn project_hours<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
Write a bar-graph representation of the tasks by hour in the current day to the supplied
EventWriter.
§Errors
Could return any formatting error
Sourcepub fn task_pie<W: Write>(
&self,
w: &mut EventWriter<W>,
proj: &str,
percent: &Percent,
) -> Result<()>
pub fn task_pie<W: Write>( &self, w: &mut EventWriter<W>, proj: &str, percent: &Percent, ) -> Result<()>
Write a pie chart representing the tasks for the supplied project to the supplied
EventWriter.
§Errors
Could return any formatting error
Sourcepub fn write<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
pub fn write<W: Write>(&self, w: &mut EventWriter<W>) -> Result<()>
Write the charts for the current day to the supplied EventWriter.
§Errors
Could return any formatting error
Auto Trait Implementations§
impl<'a> Freeze for DailyChart<'a>
impl<'a> RefUnwindSafe for DailyChart<'a>
impl<'a> Send for DailyChart<'a>
impl<'a> Sync for DailyChart<'a>
impl<'a> Unpin for DailyChart<'a>
impl<'a> UnwindSafe for DailyChart<'a>
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