| 1 | 3 | ▶ | use warnings; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 2 | 3 | ▶ | use strict; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 3 | |||
| 4 | package Data::ICal::Entry::TimeZone; | ||
| 5 | |||
| 6 | 3 | ▶ | use base qw/Data::ICal::Entry/; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | =head1 NAME | ||
| 9 | |||
| 10 | Data::ICal::Entry::TimeZone - Represents a time zone definition in an iCalendar file | ||
| 11 | |||
| 12 | =head1 SYNOPSIS | ||
| 13 | |||
| 14 | my $vtimezone = Data::ICal::Entry::TimeZone->new(); | ||
| 15 | $vtimezone->add_properties( | ||
| 16 | tzid => "US-Eastern", | ||
| 17 | tzurl => "http://zones.stds_r_us.net/tz/US-Eastern" | ||
| 18 | ); | ||
| 19 | |||
| 20 | $vtimezone->add_entry($daylight); # daylight/ standard not yet implemented | ||
| 21 | $vtimezone->add_entry($standard); # :-( | ||
| 22 | |||
| 23 | $calendar->add_entry($vtimezone); | ||
| 24 | |||
| 25 | =head1 DESCRIPTION | ||
| 26 | |||
| 27 | A L<Data::ICal::Entry::TimeZone> object represents the declaration of | ||
| 28 | a time zone in an iCalendar file. (Note that the iCalendar RFC refers | ||
| 29 | to entries as "components".) It is a subclass of L<Data::ICal::Entry> | ||
| 30 | and accepts all of its methods. | ||
| 31 | |||
| 32 | This module is not yet useful, because every time zone declaration | ||
| 33 | needs to contain at least one C<STANDARD> or C<DAYLIGHT> component, | ||
| 34 | and these have not yet been implemented. | ||
| 35 | |||
| 36 | =head1 METHODS | ||
| 37 | |||
| 38 | =cut | ||
| 39 | |||
| 40 | =head2 ical_entry_type | ||
| 41 | |||
| 42 | Returns C<VTIMEZONE>, its iCalendar entry name. | ||
| 43 | |||
| 44 | =cut | ||
| 45 | |||
| 46 | 10 | ▶ | sub ical_entry_type {'VTIMEZONE'} |
|
Subroutine
ical_entry_type: called CC=1 SCAR=0.0
Pod
documented
| |||
| 47 | |||
| 48 | =head2 optional_unique_properties | ||
| 49 | |||
| 50 | According to the iCalendar standard, the following properties may be | ||
| 51 | specified at most one time for a time zone declaration: | ||
| 52 | |||
| 53 | last-modified tzurl | ||
| 54 | |||
| 55 | =cut | ||
| 56 | |||
| 57 | 20 | ▶ | sub optional_unique_properties { |
|
Subroutine
optional_unique_properties: called CC=1 SCAR=0.0
Pod
documented
| |||
| 58 | 20 | qw( | |
| 59 | last-modified tzurl | ||
| 60 | ); | ||
| 61 | } | ||
| 62 | |||
| 63 | =head2 mandatory_unique_properties | ||
| 64 | |||
| 65 | According to the iCalendar standard, the C<tzid> property must be | ||
| 66 | specified exactly one time in a time zone declaration. | ||
| 67 | |||
| 68 | =cut | ||
| 69 | |||
| 70 | 22 | ▶ | sub mandatory_unique_properties { |
|
Subroutine
mandatory_unique_properties: called CC=1 SCAR=0.0
Pod
documented
| |||
| 71 | 22 | qw( | |
| 72 | tzid | ||
| 73 | ); | ||
| 74 | } | ||
| 75 | |||
| 76 | =head1 AUTHOR | ||
| 77 | |||
| 78 | Best Practical Solutions, LLC E<lt>modules@bestpractical.comE<gt> | ||
| 79 | |||
| 80 | =head1 LICENCE AND COPYRIGHT | ||
| 81 | |||
| 82 | Copyright (c) 2005 - 2020, Best Practical Solutions, LLC. All rights reserved. | ||
| 83 | |||
| 84 | This module is free software; you can redistribute it and/or | ||
| 85 | modify it under the same terms as Perl itself. See L<perlartistic>. | ||
| 86 | |||
| 87 | =cut | ||
| 88 | |||
| 89 | 3 | 1; | |