| SchoolDays.pm | 
  $school1 = new SchoolDays("EACMSI",             # School name
                 "9/3-12/19",                     # School dates
                 "9/30,10/9,10/10,10/13,11/11,11/13,11/14,11/26-11/28");
  if ($school1->is_school_today()) {
    ...
  } elsif ($school1->is_school_tomorrow()) {
    ...
  }
  $school1->is_school_day("mm/dd/yy");    # Date format is $config_parms{"date_format"};
  $school1->is_school_night("mm/dd/yy");  $ Can also use an ISO8601 date
  $school1->set_logging(0|1);             # LoggingThese function will calculate if Today or Tomorrow are schooldays. Multiple schools are supported. A list of term dates and an optional list of mid-term holidays are required for each school.
newInitialize with school name, session dates, and exceptions
_get_epoch_dateReturn ISO8601 date for today
_hr_dateReturn human readable date
_logLog a message
set_loggingToggle logging
is_schooldayIs the supplied day a school day
is_schoolnightIs the supplied day a school night
is_school_todayIs today a school day?
is_school_tomorrowIs tomorrow a school day?
NONE
Andrew C Baker / andrew@rekabuk.co.uk
Jeffrey C Honig / jch@honig.net
NONE
This program 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 2 of the License, or (at your option) any later version.
This program 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 this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
| SchoolDays.pm |