Various fixes for EBCDIC platforms.
[p5sagit/p5-mst-13.2.git] / ext / Time / Piece / README
CommitLineData
16433e2b 1Time::Piece
2===========
3
4This module supercedes Time::Object (and has a better name).
5
6At this time the module is almost identical to Time::Object, with
7the exception of strptime support. People using Time::Object should
8migrate over to Time::Piece as they are able to do so. No further
9development will occur to Time::Object.
10
11DESCRIPTION
12
13Have you ever thought you time was thoroughly wasted by doing:
14
15 $ perldoc -f localtime
16
17just to recall the position of wday or some other item in the returned
18list of values from localtime (or gmtime) ?
19
20Well Time::Piece is the answer to your prayers.
21
22Time::Piece does the right thing with the return value from localtime:
23
24 - in list context it returns a list of values
25
26 - in scalar context it returns a Time::Piece object
27
28 - when stringified (or printed), Time::Piece objects look like
29 the output from scalar(localtime)
30
31Beyond that, Time::Piece objects allow you to get any part of the
32date/time via method calls, plus they allow you to get at the string
33form of the week day and month. It has methods for julian days, and
34some simple date arithmetic options.
35
36Time::Piece also gives you easy access to your C library's strftime
37and strptime functions, so you can parse and output locale sensitive
38dates to your heart's content :-)
39