Difference between revisions of "PascalTZ"
(Seems like it's impossible to add comments. Anyway, I added both FPC and Lazarus because the unit is useful for both environments!) |
(Updated to reflect new home, removed redundancies.) |
||
Line 1: | Line 1: | ||
=== About === | === About === | ||
− | |||
− | |||
− | + | PascalTZ stands for "Pascal Time Zone". It allows you to convert between local times in various [http://en.wikipedia.org/wiki/Time_zone time zones] and [http://en.wikipedia.org/wiki/Gmt GMT]/[http://en.wikipedia.org/wiki/Coordinated_Universal_Time UTC], taking into account historical changes to time zone rules. PascalTZ uses the [https://www.iana.org/time-zones Time Zone Database] (often called <tt>tz</tt> or <tt>zoneinfo</tt>) to determine how to correctly adjust time for various time zones. The correctness of time zone conversions in future relies on using an up to date database. Beware, time zone rules may be changed by governments around the world, sometimes with a very short notice. | |
− | |||
− | |||
− | |||
− | + | PascalTZ component can be used in pure FPC projects or installed as a design and runtime package in Lazarus IDE. It also comes with a testing framework, a collection of time zone conversion test vectors and test cases for internal functions. | |
− | + | More information can be found at [https://github.com/dezlov/PascalTZ GitHub:PascalTZ]. | |
− | + | === Authors === | |
+ | |||
+ | This library was originally published by [[User:Joshy|José Mejuto]] in 2009 and is maintained by [[User:dezlov|Denis Kozlov]] since 2015. | ||
=== License === | === License === | ||
− | [http://svn.freepascal.org/svn/lazarus/trunk/COPYING.modifiedLGPL | + | |
+ | [http://svn.freepascal.org/svn/lazarus/trunk/COPYING.modifiedLGPL Modified] [http://svn.freepascal.org/svn/lazarus/trunk/COPYING.LGPL LGPL] (same as the FPC RTL and the Lazarus LCL). | ||
=== Download === | === Download === | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | + | [https://github.com/dezlov/PascalTZ/releases GitHub:PascalTZ releases] | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
=== Change Log === | === Change Log === | ||
− | * Version 1.0 2009 | + | * Version 1.0 (2009-11-10) [https://github.com/dezlov/PascalTZ/blob/v2.0/CHANGELOG.md] |
− | + | * Version 2.0 (2016-07-19) [https://github.com/dezlov/PascalTZ/blob/v2.0/CHANGELOG.md] | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | === | + | === Bug Reports === |
− | + | Bug reports and suggestions can be logged at [https://github.com/dezlov/PascalTZ/issues GitHub:PascalTZ issues]. | |
− | |||
=== See also === | === See also === | ||
− | |||
− | + | Since 2.6.2, FPC has the functions <code>LocalTimeToUniversal</code> and <code>UniversalTimeToLocal</code> in the ''dateutils'' unit to convert between local time and UTC time. These functions can be useful and an alternative for PascalTZ if you are not interested in historical/future date/times (i.e. the functions use current daylight saving time etc to convert to/from UTC time). These functions do allow for specifying manual offsets against UTC, but then you would need to keep track of those offsets - which PascalTZ does for you. | |
[[Category:Components]] | [[Category:Components]] |
Revision as of 10:17, 20 July 2016
About
PascalTZ stands for "Pascal Time Zone". It allows you to convert between local times in various time zones and GMT/UTC, taking into account historical changes to time zone rules. PascalTZ uses the Time Zone Database (often called tz or zoneinfo) to determine how to correctly adjust time for various time zones. The correctness of time zone conversions in future relies on using an up to date database. Beware, time zone rules may be changed by governments around the world, sometimes with a very short notice.
PascalTZ component can be used in pure FPC projects or installed as a design and runtime package in Lazarus IDE. It also comes with a testing framework, a collection of time zone conversion test vectors and test cases for internal functions.
More information can be found at GitHub:PascalTZ.
Authors
This library was originally published by José Mejuto in 2009 and is maintained by Denis Kozlov since 2015.
License
Modified LGPL (same as the FPC RTL and the Lazarus LCL).
Download
Change Log
Bug Reports
Bug reports and suggestions can be logged at GitHub:PascalTZ issues.
See also
Since 2.6.2, FPC has the functions LocalTimeToUniversal
and UniversalTimeToLocal
in the dateutils unit to convert between local time and UTC time. These functions can be useful and an alternative for PascalTZ if you are not interested in historical/future date/times (i.e. the functions use current daylight saving time etc to convert to/from UTC time). These functions do allow for specifying manual offsets against UTC, but then you would need to keep track of those offsets - which PascalTZ does for you.