I needed to convert some date times to one timezone to another, and I found your TZDB project.
It works like a charm, so It have saved me a lot of time. Many thanks 😊
But I’m missing one thing. I have tried to implement what I need, inheriting my own class from TBundledTimeZone, but all the data I need is Private or under the implementation section, so I can’t access it without modifying the original sources.
What I am missing is a function to get the year/date when a Standard or Daylight rule start for a given year.
Let me explain… I have seen that the function DaylightTimeStart(Year) returns the day and time of the Daylight segment for the given year, but I need to know when the rule applied to get that Daylight segment started to be applied.
Browsing TZDB.pas, I have seen that that info is in CFamily_X_Arr:
{ Date-bound rules for EU family }
CFamily_1_Arr: array[0 .. 5] of TYearBoundRule = (
I needed to convert some date times to one timezone to another, and I found your TZDB project.
It works like a charm, so It have saved me a lot of time. Many thanks 😊
But I’m missing one thing. I have tried to implement what I need, inheriting my own class from TBundledTimeZone, but all the data I need is Private or under the implementation section, so I can’t access it without modifying the original sources.
What I am missing is a function to get the year/date when a Standard or Daylight rule start for a given year.
Let me explain… I have seen that the function DaylightTimeStart(Year) returns the day and time of the Daylight segment for the given year, but I need to know when the rule applied to get that Daylight segment started to be applied.
Browsing TZDB.pas, I have seen that that info is in CFamily_X_Arr:
{ Date-bound rules for EU family }
CFamily_1_Arr: array[0 .. 5] of TYearBoundRule = (
);
This info is important to properly define a timezone in a iCalendar (.ics) file.
Would it be possible to include the function I need (something like DaylightRuleStartYear/Date - StandardRuleStartYear/Date) in next distributions?
I think it could be helpful for many people too.