Date::Calendar

Calendar objects for different holiday schemes
Download

Date::Calendar Ranking & Summary

Advertisement

  • Rating:
  • License:
  • Perl Artistic License
  • Price:
  • FREE
  • Publisher Name:
  • Steffen Beyer
  • Publisher web site:
  • http://search.cpan.org/~stbey/

Date::Calendar Tags


Date::Calendar Description

Calendar objects for different holiday schemes Date::Calendar is a Perl module with calendar objects for different holiday schemes.MOTTOThere is more than one way to do it - this is just one of them!PREFACEBasically, Date::Calendar is just a caching proxy class for Date::Calendar::Year objects, which are embedded in each Date::Calendar object.However, and in contrast to Date::Calendar::Year methods, Date::Calendar methods permit calculations spanning an arbitrary number of years, without loss of efficiency.So you should usually use Date::Calendar and not Date::Calendar::Year, since that way you don't have to worry about calculations crossing year boundaries.Note however that Date::Calendar and Date::Calendar::Year can only deal with years lying within the range .SYNOPSIS use Date::Calendar::Profiles qw( $Profiles ); use Date::Calendar; $calendar_US_AZ = Date::Calendar->new( $Profiles->{'US-AZ'} ); $calendar_DE_SN = Date::Calendar->new( $Profiles->{'DE-SN'} ); $year_2000_US_AZ = $calendar_US_AZ->year( 2000 ); $year_2001_DE_SN = $calendar_DE_SN->year( 2001 ); @years = $calendar->cache_keys(); # returns list of year numbers @years = $calendar->cache_vals(); # returns list of year objects $calendar->cache_clr(); $calendar->cache_add(YEAR|DATE,...); $calendar->cache_del(YEAR|DATE,...); $index = $calendar->date2index(YEAR,MONTH,DAY|DATE); @names = $calendar->labels(YEAR,MONTH,DAY|DATE); @holidays = $calendar->labels(); $holidays = $calendar->labels(); @dates = $calendar->search(PATTERN); $dates = $calendar->search(PATTERN); $hashref = $calendar->tags(YEAR,MONTH,DAY|DATE); $days = $calendar->delta_workdays(YEAR1,MONTH1,DAY1|DATE1 ,YEAR2,MONTH2,DAY2|DATE2 ,FLAG1,FLAG2); ($date,$rest) = $calendar->add_delta_workdays(YEAR,MONTH,DAY|DATE ,DELTA); $date = $calendar->add_delta_workdays(YEAR,MONTH,DAY|DATE ,DELTA); $flag = $calendar->is_full(YEAR,MONTH,DAY|DATE); $flag = $calendar->is_half(YEAR,MONTH,DAY|DATE); $flag = $calendar->is_work(YEAR,MONTH,DAY|DATE); Requirements: · Perl


Date::Calendar Related Software