I thought you meant offset from UTC.
I've never seen a standardized time based on seconds with any other offset. The >=days types uses julian days (ints or reals), since that makes sense there. The conversion for lesser units works here, though:
Calendar.Second("julian",2345455.7);
(1) Result: Second(Mon 15 Jul 1709 6:00:13 LMT)
Ah, and I found how you specify the time unit:
Calendar.Second("unix",2345455);
(2) Result: Second(Wed 28 Jan 1970 4:30:55 CET)
Calendar.Day("unix",2345455);
(3) Result: Day(Wed 28 Jan 1970)
but it doesn't work for Year(), hmm...
/ Mirar
Previous text:
2003-06-01 23:52: Subject: Re: Pike Cookbook
It does too. On my system time() returns a value counting the number of seconds from January 1 1970.
Other theoretical offsets are for instance the year zero for a given calendar.
What I'm saying is that unixtime might not be the only time encountered by pike.
/ Peter Lundqvist (disjunkt)