From: Martin <martin.dowie@btopenworld.com>
Subject: Re: Newbie Q: How to program in UTC (time/calendar) ?
Date: Tue, 24 Mar 2009 03:07:12 -0700 (PDT)
Date: 2009-03-24T03:07:12-07:00 [thread overview]
Message-ID: <e7bc1f3b-3358-4251-b93f-227a29b63982@j8g2000yql.googlegroups.com> (raw)
In-Reply-To: 89277c47-788d-441c-95b2-f47e1b70a532@j39g2000yqn.googlegroups.com
On 24 Mar, 08:51, reinkor <rein...@gmail.com> wrote:
> What is the "natural"/best way to make an Ada program
> treat time/calendar data in UTC ? The quetion is about
> treating old measurements/data tagged with UTC time.
>
> I use
>
> Offset : Constant Time_Offset := UTC_Time_Offset;
>
> and include "Time_Zone=>Offset" in calendar routines
> (for example in the functions Time_Of, Split, Value
> within the packages Ada.Calendar.Formatting and
> Ada.Calendar.Time_Zones).
>
> I find this a but "artificial". How should one do it?
>
> reinert
Dmitry raises some issue which I'm sure the ARG are looking at but you
_might_ be perfectly ok if all you're doing reading log files, etc and
not actually trying to combine this with a clock your program is
reading and expecting them to tie together with the time on your wrist
watch. And if your log didn't come from a run over summer-time
changes, leap seconds etc on an OS that actually dealt with such
things.
Cheers
-- Martin
next prev parent reply other threads:[~2009-03-24 10:07 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-24 8:51 Newbie Q: How to program in UTC (time/calendar) ? reinkor
2009-03-24 9:18 ` Dmitry A. Kazakov
2009-03-24 10:07 ` Martin [this message]
2009-03-24 10:55 ` reinkor
2009-03-24 12:49 ` Martin
2009-03-24 18:53 ` Dirk Heinrichs
2009-03-24 23:59 ` Martin
2009-03-25 10:21 ` reinkor
2009-03-25 15:28 ` tmoran
2009-03-25 21:55 ` sjw
2009-03-26 1:38 ` tmoran
2009-03-26 20:58 ` sjw
2009-03-27 12:52 ` reinkor
2009-03-27 16:58 ` Jeffrey R. Carter
2009-03-30 11:27 ` reinkor
2009-03-30 16:47 ` Jeffrey R. Carter
2009-03-30 12:37 ` reinkor
2009-03-30 13:45 ` John B. Matthews
2009-03-30 16:52 ` Jeffrey R. Carter
2009-03-30 19:34 ` reinkor
2009-03-30 19:44 ` reinkor
2009-04-04 2:22 ` Brian Gaffney
2009-03-24 11:29 ` Jacob Sparre Andersen
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox