Expand description
system-time
A library for fetching the current time based on the system’s locale settings.
Constants§
- COMMON_
YEAR - Day count of every month in a common (non-leap) year.
- DAYS
- Abbreviated English weekday names, indexed by weekday number.
- LANG_
AR_ SA_ LOCALE - POSIX locale string of the Arabic (Saudi Arabia) UTF-8 encoding.
- LANG_
AR_ SA_ NAME - Human-readable name of the Arabic (Saudi Arabia) locale.
- LANG_
DE_ DE_ LOCALE - POSIX locale string of the German (Germany) UTF-8 encoding.
- LANG_
DE_ DE_ NAME - Human-readable name of the German (Germany) locale.
- LANG_
ENV_ VAR - Environment variable holding the locale of the current session.
- LANG_
EN_ US_ LOCALE - POSIX locale string of the English (United States) UTF-8 encoding.
- LANG_
EN_ US_ NAME - Human-readable name of the English (United States) locale.
- LANG_
ES_ ES_ LOCALE - POSIX locale string of the Spanish (Spain) UTF-8 encoding.
- LANG_
ES_ ES_ NAME - Human-readable name of the Spanish (Spain) locale.
- LANG_
FI_ FI_ LOCALE - POSIX locale string of the Finnish (Finland) UTF-8 encoding.
- LANG_
FI_ FI_ NAME - Human-readable name of the Finnish (Finland) locale.
- LANG_
FR_ FR_ LOCALE - POSIX locale string of the French (France) UTF-8 encoding.
- LANG_
FR_ FR_ NAME - Human-readable name of the French (France) locale.
- LANG_
HI_ IN_ LOCALE - POSIX locale string of the Hindi (India) UTF-8 encoding.
- LANG_
HI_ IN_ NAME - Human-readable name of the Hindi (India) locale.
- LANG_
IT_ IT_ LOCALE - POSIX locale string of the Italian (Italy) UTF-8 encoding.
- LANG_
IT_ IT_ NAME - Human-readable name of the Italian (Italy) locale.
- LANG_
JA_ JP_ LOCALE - POSIX locale string of the Japanese (Japan) UTF-8 encoding.
- LANG_
JA_ JP_ NAME - Human-readable name of the Japanese (Japan) locale.
- LANG_
KO_ KR_ LOCALE - POSIX locale string of the Korean (South Korea) UTF-8 encoding.
- LANG_
KO_ KR_ NAME - Human-readable name of the Korean (South Korea) locale.
- LANG_
NL_ NL_ LOCALE - POSIX locale string of the Dutch (Netherlands) UTF-8 encoding.
- LANG_
NL_ NL_ NAME - Human-readable name of the Dutch (Netherlands) locale.
- LANG_
PT_ PT_ LOCALE - POSIX locale string of the Portuguese (Portugal) UTF-8 encoding.
- LANG_
PT_ PT_ NAME - Human-readable name of the Portuguese (Portugal) locale.
- LANG_
RU_ RU_ LOCALE - POSIX locale string of the Russian (Russia) UTF-8 encoding.
- LANG_
RU_ RU_ NAME - Human-readable name of the Russian (Russia) locale.
- LANG_
SV_ SE_ LOCALE - POSIX locale string of the Swedish (Sweden) UTF-8 encoding.
- LANG_
SV_ SE_ NAME - Human-readable name of the Swedish (Sweden) locale.
- LANG_
TH_ TH_ LOCALE - POSIX locale string of the Thai (Thailand) UTF-8 encoding.
- LANG_
TH_ TH_ NAME - Human-readable name of the Thai (Thailand) locale.
- LANG_
VI_ VN_ LOCALE - POSIX locale string of the Vietnamese (Vietnam) UTF-8 encoding.
- LANG_
VI_ VN_ NAME - Human-readable name of the Vietnamese (Vietnam) locale.
- LANG_
ZH_ CN_ LOCALE - POSIX locale string of the Chinese (China) UTF-8 encoding.
- LANG_
ZH_ CN_ NAME - Human-readable name of the Chinese (China) locale.
- LEAP_
YEAR - Day count of every month in a leap year.
- MONTHS
- Abbreviated English month names, indexed by month number minus one.
Functions§
- calculate_
time - Calculates the current year, month, day, hour, minute, second, millisecond and microsecond.
- compute_
date - Computes the year, month, and day from days since Unix epoch (1970-01-01).
- date
- Gets the current day, without the time.
- day
- Gets the current day.
- from_
env_ var - Gets the time zone offset from the system environment variable.
- gmt
- Gets the current date and time in GMT format.
- hour
- Gets the current hour.
- is_
leap_ year - Determines if a year is a leap year.
- micros
- Gets the current timestamp in microseconds.
- millis
- Gets the current timestamp in milliseconds.
- minute
- Gets the current minute.
- month
- Gets the current month.
- second
- Gets the current second.
- time
- Gets the current time, including the date and time.
- time_
micros - Gets the current time with microseconds, including the date and time.
- time_
millis - Gets the current time with milliseconds, including the date and time.
- timestamp
- Gets the current timestamp in seconds since Unix epoch.
- timestamp_
micros - Gets the current timestamp in microseconds since Unix epoch.
- timestamp_
millis - Gets the current timestamp in milliseconds since Unix epoch.
- year
- Gets the current year.