• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

examples/H15-Oct-2009-2,0781,605

lib/Date/H15-Oct-2009-8,2706,739

src/H15-Oct-2009-8,7427,296

t/H15-Oct-2009-8,8827,068

tools/H15-Oct-2009-858475

MANIFESTH A D15-Oct-20091.4 KiB101100

META.ymlH A D15-Oct-2009412 1514

Makefile.PLH A D15-Oct-20095.6 KiB202154

Pcalc.podH A D15-Oct-2009107 KiB3,3112,350

Pcalendar.pmH A D15-Oct-20096.4 KiB292238

Pcalendar.podH A D15-Oct-200920.2 KiB608423

README.htmH A D15-Oct-20097.7 KiB142104

README.htm

1<HTML>
2<HEAD>
3    <META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
4    <TITLE>Date::Pcalc Readme Page</TITLE>
5</HEAD>
6<BODY>
7
8<P>
9<HR NOSHADE SIZE="2">
10<P>
11
12<CENTER>
13If you are looking for information on <A HREF="CHANGES.txt">what is new</A> in this version, prerequisites and <A HREF="INSTALL.txt">installation instructions</A>, you will find it either in the <A HREF="README.txt">README</A> file included in this distribution, <A HREF="http://www.engelschall.com/~sb/download/pkg/Date-Pcalc-6.1.README">on my website</A> or <A HREF="http://cpansearch.perl.org/src/STBEY/Date-Pcalc-6.1/README.txt">on CPAN</A>.
14</CENTER>
15
16<P>
17<HR NOSHADE SIZE="2">
18<P>
19
20<H3>See</H3>
21<A HREF="http://search.cpan.org/search?module=Date::Pcalc"><IMG SRC="http://www.engelschall.com/u/sb/download/Date-Calc/img/cpan_banner.png" ALT="[search.cpan.org]" BORDER="0"></A>
22<H3>for the latest manual page.</H3>
23
24<P>
25
26<H1>Date::Pcalc</H1>
27<A HREF="http://www.engelschall.com/u/sb/demo/"><IMG SRC="http://www.engelschall.com/u/sb/download/img/Date-Calc.gif" ALT="[Date::Pcalc]" WIDTH="455" HEIGHT="230" BORDER="0"></A>
28
29<P>
30
31<H3>What is it for?</H3>
32
33Date calculations, e.g.
34
35<UL>
36    <LI>&quot;Basic stuff&quot; like leap year, &quot;Julian day&quot; (or &quot;date&quot;), day-of-week, days in month/year, etc.
37    <LI>Comparing dates
38    <LI>Conversion from a date (e.g. 01-Jun-2004) to the number of days (e.g. 731733) and vice-versa
39    <LI>Calculating a date (e.g. 01-Jun-2004) plus/minus a number of days (e.g. +35) yielding a new date (e.g. 06-Jul-2004)
40    <LI>Calculating the nth day-of-week of a month and year (e.g. the first Tuesday of July 2004 = 06-Jul-2004)
41    <LI>Calculating differences between dates (and/or times)
42    <LI>Calculating Easter Sunday and holidays depending on it
43    <LI>...
44
45</UL>
46
47based on
48
49<UL>
50    <LI>the Gregorian calendar (decreed in 1582 by pope Gregor I)
51    <LI><A HREF="http://www.engelschall.com/u/sb/download/Date-Calc/DIN1355/">DIN 1355</A>
52    <LI><A HREF="http://www.iso.ch/iso/en/prods-services/popstds/datesandtime.html">ISO 8601</A> (to some extent, where applicable)
53    <BR>(See also <A HREF="http://www.w3.org/TR/NOTE-datetime">W3C</A>, <A HREF="http://www.mcs.vuw.ac.nz/technical/software/SGML/doc/iso8601/ISO8601.html">Victoria University of Wellington</A> or <A HREF="http://en.wikipedia.org/wiki/ISO_8601">Wikipedia</A>)
54
55</UL>
56
57<H3>Philosophy</H3>
58
59<UL>
60    <LI>Toolbox, not a (heavy) ready-made application
61    <LI>Interoperable, &quot;LEGO system&quot;
62    <LI>Spirit of UNIX command-line tools (be small, do only one thing, and be good at it)
63    <LI>Be computationally complete, i.e., everything should be computable (even if it takes a little more than only one function call)
64</UL>
65
66<H3>What it is <B><U>NOT</U></B></H3>
67
68<UL>
69    <LI>A jack-of-all-trades (see e.g. <A HREF="http://search.cpan.org/search?module=Date::Manip">Date::Manip</A> instead)
70    <LI>A module specializing in date parsing (see e.g. <A HREF="http://search.cpan.org/search?module=Date::Parse">Date::Parse</A>, <A HREF="http://search.cpan.org/search?module=Time::ParseDate">Time::ParseDate</A> or <A HREF="http://search.cpan.org/search?module=Date::Manip">Date::Manip</A> instead)
71    <LI>A module specializing in date formatting (see e.g. <A HREF="http://search.cpan.org/search?module=Date::Format">Date::Format</A> or <A HREF="http://search.cpan.org/search?module=Date::Manip">Date::Manip</A> instead)
72    <LI>A module specializing in the handling of timezones (see e.g. <A HREF="http://search.cpan.org/search?module=Time::Timezone">Time::Timezone</A> or <A HREF="http://search.cpan.org/search?module=Time::Zone">Time::Zone</A> instead)
73
74</UL>
75
76<H3>What it <B><U>IS</U></B></H3>
77
78<UL>
79    <LI>A module <B><U>primarily</U></B> for performing <B><U>calculations</U></B> with dates (nomen est omen)
80    <LI>A module intended to be <B><U>small</B></U> (low memory footprint) and <B><U>fast</B></U> (for heavy-duty applications)
81</UL>
82
83<P>
84
85<H3>Features</H3>
86
87<UL>
88
89    <LI>Extrapolates the Gregorian calendar back beyond 1582 until 1 A.D.
90    <BR>(historically <B><U>not</B></U> meaningful, but may nevertheless be useful)
91    <LI>Numerical range extends as far as &quot;int&quot; data type permits, i.e., at least until the year 32767
92    <LI>Basic date parsing (input) and formatting (output)
93    <LI>Support for various languages (input and output)
94    <BR>(Currently 14 as of version 6.1; English, French, German, Spanish, Portuguese, Dutch, Italian, Norwegian, Swedish, Danish, Finnish, Hungarian, Polish and Romanian)
95    <LI>Calculations on dates, with and without time (including timezone offsets)
96    <LI>Interface to localtime(), gmtime(), mktime() plus own conversion routines (with more predictable results)
97    <LI><B>Internally written in C for smaller memory usage, faster execution and possibility to use in C applications</B>
98    <LI>The <A HREF="http://search.cpan.org/search?module=Date::Pcalc">documentation</A> of &quot;Date::Pcalc&quot; gives model solutions to common problems in its &quot;<A HREF="http://search.cpan.org/~stbey/Date-Pcalc-6.1/Pcalc.pod#RECIPES">RECIPES</A>&quot; section
99    <LI>Optionally provides date objects (i.e., an OO interface) for greater ease of use (Perl only) (<A HREF="http://search.cpan.org/search?module=Date::Pcalc::Object">Date::Pcalc::Object</A>)
100    <LI>Comprises a module for date calculations taking legal holidays into account (Perl only) (<A HREF="http://search.cpan.org/search?module=Date::Pcalendar">Date::Pcalendar</A>)
101    <LI>Provides a rich set of holiday profiles for numerous countries (Perl only) (<A HREF="http://search.cpan.org/search?module=Date::Pcalendar::Profiles">Date::Pcalendar::Profiles</A>)
102
103</UL>
104
105<H3>Limitations</H3>
106
107<UL>
108    <LI>The language setting in &quot;Date::Pcalc&quot; is a global variable (= BEWARE when using threads!)
109    <LI>The modules &quot;Date::Pcalendar&quot; and &quot;Date::Pcalendar::Year&quot; only operate on years between 1583 and 2299
110    <LI>Uses the ISO-Latin-1 character set, even for languages (such as Polish) not entirely representable in that character set (uses the &quot;plain&quot; characters instead in such cases)
111    <LI><FONT COLOR="#FF0000"><B>The calendar profiles included in this module usually do not take historical irregularities into account</B></FONT> (even though some do in order to show how this can be done),<BR>
112        <FONT COLOR="#FF0000"><B>they only provide means for calculating <U>regularly</U> recurring events (<U>the profiles should therefore not be relied upon for historical faithfulness</U>)</B></FONT>
113
114</UL>
115
116<P>
117
118<H3>See also</H3>
119
120<UL>
121    <LI>The <A HREF="http://www.engelschall.com/u/sb/calendar/">International Eternal Gregorian Calendar</A> showing a calendar with holidays in selectable languages and countries
122    <LI>The <A HREF="http://www.engelschall.com/u/sb/demo/">Sports Club Events Calendar</A> showing how this module can be used to manage people attending events in a calendar
123    <LI>The <A HREF="http://www.engelschall.com/u/sb/datecalc/">Simple Date Calculator</A> for determining the difference between two dates / a new date based on a date plus a difference
124    <LI>&quot;<A HREF="http://www.tondering.dk/claus/calendar.html">The Calendar FAQ</A>&quot; by <A HREF="mailto:claus@tondering.dk">Claus T�ndering</A>
125
126</UL>
127
128<P>
129<HR NOSHADE SIZE="2">
130<P>
131
132<CENTER>
133If you are looking for information on <A HREF="CHANGES.txt">what is new</A> in this version, prerequisites and <A HREF="INSTALL.txt">installation instructions</A>, you will find it either in the <A HREF="README.txt">README</A> file included in this distribution, <A HREF="http://www.engelschall.com/~sb/download/pkg/Date-Pcalc-6.1.README">on my website</A> or <A HREF="http://cpansearch.perl.org/src/STBEY/Date-Pcalc-6.1/README.txt">on CPAN</A>.
134</CENTER>
135
136<P>
137<HR NOSHADE SIZE="2">
138<P>
139
140</BODY>
141</HTML>
142