Documentation
¶
Overview ¶
Package windowsiana provides support in converting date timezones from the non-standard windows timezone format into UTC. It also provides a function to return a timezone-aware date given a date string and an IANA timezone the date can then be used as a UTC date via the .UTC() function
Index ¶
Constants ¶
This section is empty.
Variables ¶
var WinIANA = map[string]string{}/* 156 elements not displayed */
WinIANA is a pseudo constant that provides a mapping between the Windows timezones and the IANA zones CAUTION : I can't vouch for the ongoing reliability/accuracy of the mapping, which is partly why I've made this an accessible variable so that you can update it at runtime if needs be
Functions ¶
func StripTimezoneFromDate ¶
StripTimezoneFromDate removes the same point in time and date, but strips apart the timezone
func TimezoneParseIANA ¶
TimezoneParseIANA accepts a timestring in the format "2006-01-02T15:04:05" as the tstring parameter and am IANA time zone (eg "Pacific/Fiji") as the timezone. It will return a timezoned date, which will correctly handle daylight savings time if it's in force at the given date
func TimezoneParseWindows ¶
TimezoneParseWindows accepts a timestring in the format "2006-01-02T15:04:05" as the tstring parameter and a windows time zone (eg "(UTC+12:00) Fiji") as the timezone. It will return a timezoned date, which will correctly handle daylight savings time if it's in force at the given date
Types ¶
This section is empty.