Shane Landrum

NAME

Net::ICal::Timezone -- class for representing VTIMEZONEs

DESCRIPTION

This module represents VTIMEZONEs, which detail important information about timezones. For any timezone, you need to know some important factors related to it, namely:

  • What UTC offset it's in now ('8 hours before GMT')

  • What UTC offset it'll be in at the next daylight/standard time shift

  • When the shifts to and from daylight savings time take place

This object represents those concepts with arrays of Net::ICal::Standard and Net::ICal::Daylight objects. For more detail on why, see RFC2445 4.6.5.

If you want some real data to test this module against, see http://primates.ximian.com/~damon/icalendar/zoneinfo.tgz , which is a set of VTIMEZONE files that aims to describe every timezone in the world. We'll be relying on those files in a future release as a master timezone database. They're a translation of the Olsen timezone database found on Unix systems.

SYNOPSIS

    use Net::ICal::Timezone;

    # we know this works
    my $tz = Net::ICal::Timezone->new_from_ical($ical_text);
    
    # we haven't tested this yet, patches welcome
    my $tz = Net::ICal::Timezone->new(
        tzid => 'America/New_York',
        standards => [
            (Net::ICal::Standard objects)                    
        ],
        daylights => [
            (Net::ICal::Daylight objects)
        ]
        );

METHODS

new(%args)

Makes a new Timezone object. Permissible arguments are:

  • tzid - a unique identifier for this timezone

  • lastmod - the last date/time this timezone info was updated

  • tzurl - an URL where you can find a newer version of this infi

  • standards - an array of Net::ICal::Timezone::Standard objects.

  • daylights - an array of N::I::Timezone::Daylight objects.