X-Git-Url: https://git.madduck.net/etc/awesome.git/blobdiff_plain/27e12c9a39aa33f8815964adedd036cd6703099f..30a82a3ecf764b2349cde9755686b1109ebe4b2a:/doc/tzinfo.md?ds=sidebyside diff --git a/doc/tzinfo.md b/doc/tzinfo.md index 78d0453..d4791e2 100644 --- a/doc/tzinfo.md +++ b/doc/tzinfo.md @@ -1,4 +1,4 @@ -# `luatz.tzinfo` +## `luatz.tzinfo` {#tzinfo} Provides a metatable for the timezone class. @@ -26,18 +26,18 @@ and contains the following fields: - `isgmt` (boolean) -## `:find_current ( utc_ts )` +### `tzinfo:find_current(utc_ts)` {#tzinfo:find_current} Returns the relevant `tt_info` object for the given UTC timestamp in the timezone. -## `:localise ( utc_ts )` and `:localize ( utc_ts )` +### `tzinfo:localise(utc_ts)` and `tzinfo:localize(utc_ts)` {#tzinfo:localise} Convert the given UTC timestamp to the timezone. Returns the number of seconds since unix epoch in the given timezone. -## `:utctime ( local_ts )` +### `tzinfo:utctime(local_ts)` {#tzinfo:utctime} Convert the given local timestamp (seconds since unix epoch in the time zone) to a UTC timestamp. This may result in ambigous results, in which case multiple values are returned.