App::TimeClock::Weekly::Report
Can parse the timelog and generate a report using an instance of a App::TimeClock::Weekly::PrinterInterface.
Initializes a new App::TimeClock::Weekly::Report object.
Two parameters are required:
Must point to a timelog file. Will die if not.
An object derived from App::TimeClock::Weekly::PrinterInterface. Will die if not.
Returns a time (seconds since epoch) from a date and time.
Returns the time when the report was executed.
Sets the time when the report is executed.
Reads a set of check in and check out lines.
If end of file is reached after reading the check in line, then reading of the check out line is skipped.
Parses a set of check in and check out lines.
The lines are split on space and should contain the following four fields:
is either 'i' - check in or 'o' - check out.
is formatted as YYYY/MM//DD
is formatted as HH:MM:SS
is then name of the project/task and is only required when checking in.
Opens the timelog file starts parsing it, looping over each day and calling print_day() for each.
Søren Lund, <soren at lund.org>
<soren at lund.org>
timeclock.pl
Copyright (C) 2012-2014 Søren Lund
This file is part of App::TimeClock.
App::TimeClock is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
App::TimeClock is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with App::TimeClock. If not, see <http://www.gnu.org/licenses/>.
To install App::TimeClock, copy and paste the appropriate command in to your terminal.
cpanm
cpanm App::TimeClock
CPAN shell
perl -MCPAN -e shell install App::TimeClock
For more information on module installation, please visit the detailed CPAN module installation guide.