Blame lib/Date/Manip.pod

Packit 95306a
# Copyright (c) 1995-2017 Sullivan Beck. All rights reserved.
Packit 95306a
# This program is free software; you can redistribute it and/or modify it
Packit 95306a
# under the same terms as Perl itself.
Packit 95306a
Packit 95306a
=pod
Packit 95306a
Packit 95306a
=head1 NAME
Packit 95306a
Packit 95306a
Date::Manip - Date manipulation routines
Packit 95306a
Packit 95306a
=head1 DESCRIPTION
Packit 95306a
Packit 95306a
Date::Manip is a series of modules designed to make any common
Packit 95306a
date/time operation easy to do.  Operations such as comparing two
Packit 95306a
times, determining a date a given amount of time from another, or
Packit 95306a
parsing international times are all easily done.  It deals with time
Packit 95306a
as it is used in the Gregorian calendar (the one currently in use)
Packit 95306a
with full support for time changes due to daylight saving time.
Packit 95306a
Packit 95306a
From the very beginning, the main focus of Date::Manip has been to be
Packit 95306a
able to do ANY desired date/time operation easily.  Many other modules
Packit 95306a
exist which may do a subset of these operations quicker or more
Packit 95306a
efficiently, but no other module can do all of the operations
Packit 95306a
available in Date::Manip.
Packit 95306a
Packit 95306a
Since many other date/time modules exist, some of which may do the
Packit 95306a
specific operation(s) you need faster, be sure to read
Packit 95306a
L<Date::Manip::Misc/"SHOULD I USE DATE::MANIP"> before
Packit 95306a
deciding which of the Date and Time modules from CPAN is for you.
Packit 95306a
However, if you want one module to do it all, Date::Manip is the
Packit 95306a
one to use.
Packit 95306a
Packit 95306a
Date::Manip has functionality to work with several fundamental types
Packit 95306a
of data.
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item B<dates>
Packit 95306a
Packit 95306a
The word date is used extensively here and is somewhat misleading. In
Packit 95306a
Date::Manip, a date consists of three pieces of information: a
Packit 95306a
calendar date, a time of day, and time zone information. Calendar
Packit 95306a
dates and times are fully handled. Time zones are handled as well, but
Packit 95306a
depending on how you use Date::Manip, there may be some limitations as
Packit 95306a
discussed below.
Packit 95306a
Packit 95306a
=item B<delta>
Packit 95306a
Packit 95306a
A delta is an amount of time (i.e. the amount of time between two different
Packit 95306a
dates). A delta refers only to an amount of time. It includes no information
Packit 95306a
about a starting or ending date/time.  Most people will think of a delta
Packit 95306a
as an amount of time, but the term 'time' is already used so much in this
Packit 95306a
module that I didn't want to use it here in order to avoid confusion.
Packit 95306a
Packit 95306a
=item B<recurrence>
Packit 95306a
Packit 95306a
A recurring event is something which occurs on a regular recurring
Packit 95306a
basis.
Packit 95306a
Packit 95306a
=item B<holidays> and B<events>
Packit 95306a
Packit 95306a
Holidays and events are basically named dates or recurrences.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
Among other things, Date::Manip allow you to:
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
Enter a date in practically any format you choose.
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
Compare two dates, entered in widely different formats to determine
Packit 95306a
which is earlier.
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
Extract any information you want from a date using a format string
Packit 95306a
similar to the Unix date command.
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
Determine the amount of time between two dates, or add an amount of
Packit 95306a
time to a date to get a second date.
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
Work with dates with dates using international formats (foreign month
Packit 95306a
names, 12/10/95 referring to October rather than December, etc.).
Packit 95306a
Packit 95306a
=item B<*>
Packit 95306a
Packit 95306a
To find a list of dates where a recurring event happens.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
Each of these tasks is trivial (one or two lines at most) with this package.
Packit 95306a
Packit 95306a
=head1 HOW TO USE DATE::MANIP
Packit 95306a
Packit 95306a
There are three different ways to use Date::Manip .  There are three
Packit 95306a
interfaces (version 5 functional interface, version 6 functional, and
Packit 95306a
version 6 object-oriented).  A complete description of each is
Packit 95306a
included in the L<Date::Manip::Interfaces> document.  The recommended
Packit 95306a
(and the only one with access to the full functionality of the module)
Packit 95306a
is using the Object-Oriented interface.
Packit 95306a
Packit 95306a
=head1 SEE ALSO
Packit 95306a
Packit 95306a
Because Date::Manip performs so many operations, the documentation is
Packit 95306a
extensive.  It includes the following documents:
Packit 95306a
Packit 95306a
=head2 Information about the different interfaces
Packit 95306a
Packit 95306a
Read this for a detailed description of each of the interfaces,
Packit 95306a
including information on how to choose and use the interface
Packit 95306a
best suited to your situation.
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::Interfaces>
Packit 95306a
Packit 95306a
A complete description of the functional interfaces available.  NOTE:
Packit 95306a
it is recommended that you use the OO interface wherever possible
Packit 95306a
as the functional interfaces have some imitations.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 A description of the functional interfaces:
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::DM5>
Packit 95306a
Packit 95306a
The version 5 functional interface
Packit 95306a
Packit 95306a
=item L<Date::Manip::DM6>
Packit 95306a
Packit 95306a
The version 6 functional interface
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 Objects and configuration
Packit 95306a
Packit 95306a
An introduction to the Date::Manip classes used by the object-oriented
Packit 95306a
interface and how to configure them:
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::Objects>
Packit 95306a
Packit 95306a
An overview of the various Date::Manip modules, and how to use them.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Config>
Packit 95306a
Packit 95306a
Information for configuring Date::Manip
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 Date::Manip object-oriented modules
Packit 95306a
Packit 95306a
These are the modules for using the object-oriented interface.
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::Obj>
Packit 95306a
Packit 95306a
This is the base class.  All other classes listed here inherit the
Packit 95306a
methods defined in this class.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Base>
Packit 95306a
Packit 95306a
A module for doing low-level date operations.
Packit 95306a
Packit 95306a
=item L<Date::Manip::TZ>
Packit 95306a
Packit 95306a
A module for working with time zones.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Date>
Packit 95306a
Packit 95306a
The module for working with dates.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Delta>
Packit 95306a
Packit 95306a
The module for working with deltas (amount of time).
Packit 95306a
Packit 95306a
=item L<Date::Manip::Recur>
Packit 95306a
Packit 95306a
The module for working with recurrences (recurring dates).
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 Timezone information
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::DM5abbrevs>
Packit 95306a
Packit 95306a
Time zone abbreviations used in the version 5 interface.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Zones>
Packit 95306a
Packit 95306a
Time zone data included in Date::Manip used in the version 6
Packit 95306a
interfaces.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 Miscellaneous information:
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::Calc>
Packit 95306a
Packit 95306a
Detailed information on how date calculations are done.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Holidays>
Packit 95306a
Packit 95306a
Information on defining and using holidays and events.
Packit 95306a
Packit 95306a
=item L<Date::Manip::ConfigFile>
Packit 95306a
Packit 95306a
A sample config file.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang>
Packit 95306a
Packit 95306a
Information about the languages supported by Date::Manip and how
Packit 95306a
to add a new language.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::english>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::catalan>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::danish>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::dutch>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::finnish>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::french>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::german>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::italian>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::norwegian>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::polish>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::portugue>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::romanian>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::russian>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::spanish>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::swedish>
Packit 95306a
Packit 95306a
=item L<Date::Manip::Lang::turkish>
Packit 95306a
Packit 95306a
A description of the parseable words in each language currently
Packit 95306a
supported by Date::Manip.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head2 Information about the module and administrative things:
Packit 95306a
Packit 95306a
=over 4
Packit 95306a
Packit 95306a
=item L<Date::Manip::Migration5to6>
Packit 95306a
Packit 95306a
Information on changes necessary to scripts when upgrading from
Packit 95306a
5.xx to 6.xx.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Changes5>
Packit 95306a
Packit 95306a
Change log for Date::Manip 5.xx
Packit 95306a
Packit 95306a
=item L<Date::Manip::Changes5to6>
Packit 95306a
Packit 95306a
Differences between version 5.xx and 6.00 (including information
Packit 95306a
on upgrading); this contains more details than the Migration5to6
Packit 95306a
document.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Changes6>
Packit 95306a
Packit 95306a
Change log for Date::Manip 6.xx
Packit 95306a
Packit 95306a
=item L<Date::Manip::Misc>
Packit 95306a
Packit 95306a
Miscellaneous information about Date::Manip (who should use it;
Packit 95306a
acknowledgments).
Packit 95306a
Packit 95306a
=item L<Date::Manip::History>
Packit 95306a
Packit 95306a
Musings on the history of Date::Manip written around it's
Packit 95306a
20th birthday.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Problems>
Packit 95306a
Packit 95306a
Common problems and instructions for reporting bugs.
Packit 95306a
Packit 95306a
=item L<Date::Manip::Examples>
Packit 95306a
Packit 95306a
Examples of how to use Date::Manip.
Packit 95306a
Packit 95306a
=back
Packit 95306a
Packit 95306a
=head1 LICENSE
Packit 95306a
Packit 95306a
This script is free software; you can redistribute it and/or
Packit 95306a
modify it under the same terms as Perl itself.
Packit 95306a
Packit 95306a
=head1 AUTHOR
Packit 95306a
Packit 95306a
Sullivan Beck (sbeck@cpan.org)
Packit 95306a
Packit 95306a
=cut