Add built local::lib
[catagits/Gitalist.git] / local-lib5 / lib / perl5 / DateTime / TimeZone / UTC.pm
CommitLineData
3fea05b9 1package DateTime::TimeZone::UTC;
2
3use strict;
4
5use vars qw ($VERSION);
6$VERSION = 0.01;
7
8use DateTime::TimeZone;
9use base 'DateTime::TimeZone';
10
11sub new
12{
13 my $class = shift;
14
15 return bless { name => 'UTC' }, $class;
16}
17
18sub is_dst_for_datetime { 0 }
19
20sub offset_for_datetime { 0 }
21sub offset_for_local_datetime { 0 }
22
23sub short_name_for_datetime { 'UTC' }
24
25sub category { undef }
26
27sub is_utc { 1 }
28
29
301;
31
32__END__
33
34=head1 NAME
35
36DateTime::TimeZone::UTC - The UTC time zone
37
38=head1 SYNOPSIS
39
40 my $utc_tz = DateTime::TimeZone::UTC->new;
41
42=head1 DESCRIPTION
43
44This class is used to provide the DateTime::TimeZone API needed by
45DateTime.pm for the UTC time zone, which is not explicitly included in
46the Olson time zone database.
47
48The offset for this object will always be zero.
49
50=head1 USAGE
51
52This class has the same methods as a real time zone object, but the
53C<category()> method returns undef and C<is_utc()> returns true.
54
55=head1 AUTHOR
56
57Dave Rolsky, <autarch@urth.org>
58
59=head1 COPYRIGHT & LICENSE
60
61Copyright (c) 2003-2008 David Rolsky. All rights reserved. This
62program is free software; you can redistribute it and/or modify it
63under the same terms as Perl itself.
64
65The full text of the license can be found in the LICENSE file included
66with this module.
67
68=cut