1Date::HolidayParser::iCUasleerndCaorn(t3r)ibuted Perl DoDcautmee:n:tHaotliiodnayParser::iCalendar(3)
2
3
4

NAME

6       Date::HolidayParser::iCalendar - iCalendar-like interface extension to
7       Date::HolidayParser
8

VERSION

10       0.4
11

SYNOPSIS

13       This is an extension to Date::HolidayParser that adds an iCalendar-like
14       interface to the holiday data.
15
16               use Date::HolidayParser;
17
18               my $Holidays = Date::HolidayParser->new("$ENV{HOME}/.holiday");
19
20               ...
21

DESCRIPTION

23       This is an extension to Date::HolidayParser that adds an interface that
24       provides iCalendar-compatible data instead of the normal "raw"
25       Date::HolidayParser format.
26
27       It ensures that UIDs generated are always the same, so you can depend
28       upon them not changing between runs. The iCalendar data generated at
29       the moment is very simple, and doesn't take into account recurrances
30       (recurring events gets one event created per recurrance).
31

METHODS

33       You can run any method Date::HolidayParser supports on a
34       Date::HolidayParser::iCalendar object (but then you should probably be
35       using Date::HolidayParser instead). The methods documented here are all
36       those needed to make use of Date::HolidayParser::iCalendar.
37
38   $object = Date::HolidayParser::iCalendar->new(FILE);
39       This is the main function. It creates a new
40       Date::HolidayParser::iCalendar object for FILE and parses the file.
41
42       FILE must be the full path to the holiday file you want to parse.
43
44   $arrayRef = $object->list_events(YEAR,MONTH?,DAY?);
45       This returns an arrayRef, which contains one of three lists, depending
46       on how many parameters are supplied:
47
48       Only year: An array containing a list of months (1-12) that has
49       holidays
50       Year+Month: An array of days in said month that has holidays
51       All: A list of iCalendar UIDs referring to holidays on said date. These
52       UIDs can be supplied to get_info() to retrieve the event.
53
54   $UID_Info = $object->get_info(UID);
55       Returns an iCalendar hash reference for the supplied UID or undef if
56       the UID doesn't exist.
57
58       The hash returned is structured like this:
59
60               %Hash = (
61                       ICAL_ENTRY => "ENTRY_VALUE",
62                       ANOTHER_ENTRY => "ANOTHER_VALUE",
63               );
64
65       An example might look like this:
66
67               %Hash = (
68                       'SUMMARY' => 'Monday',
69                       'UID' => 'D-HP-ICS-72-106-616',
70                       'DTEND' => '20060313',
71                       'DTSTART' => '20060313'
72               );
73

AUTHOR

75       Eskild Hustvedt - "<zerodogg@cpan.org>"
76

BUGS

78       Please report any bugs or feature requests to
79       "bug-date-holidayparser@rt.cpan.org", or through the web interface at
80       <http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Date-HolidayParser>.  I
81       will be notified, and then you'll automatically be notified of progress
82       on your bug as I make changes.
83
85       Copyright (C) 2006, 2007, 2010 Eskild Hustvedt, all rights reserved.
86
87       This program is free software; you can redistribute it and/or modify it
88       under the same terms as Perl itself. There is NO warranty; not even for
89       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
90
91
92
93perl v5.36.0                      2023-01-20 Date::HolidayParser::iCalendar(3)
Impressum