Time Functions
time.currentTimeInSeconds
Double time.currentTimeInSeconds()
Returns the current fractional seconds since the Epoch.
Parameters:
Returns:
the time since the Epoch.
time.daysToHours
<Integral T> Int64 time.daysToHours(T days)
Converts the time duration given in days to hours (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of hours (days x hours in a day = days x 24).
time.daysToMicros
<Integral T> Int64 time.daysToMicros(T days)
Converts the time duration given in days to microseconds (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of microseconds (days x (micros in a day) = days x (24 x 60 x 60 x 1000 x 1000)).
time.daysToMillis
<Integral T> Int64 time.daysToMillis(T days)
Converts the time duration given in days to milliseconds (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (days x (millis in a day) = days x (24 x 60 x 60 x 1000)).
time.daysToMinutes
<Integral T> Int64 time.daysToMinutes(T days)
Converts the time duration given in days to minutes (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of minutes (days x (minutes in a day) = days x (24 x 60)).
time.daysToNanos
<Integral T> Int64 time.daysToNanos(T days)
Converts the time duration given in days to nanoseconds (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (days x (nanos in a day) = days x (24 x 60 x 60 x 1000 x 1000 x 1000)).
time.daysToSeconds
<Integral T> Int64 time.daysToSeconds(T days)
Converts the time duration given in days to seconds (as integer).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of seconds (days x (seconds in a day) = days x (24 x 60 x 60)).
time.formatDateTime
String time.formatDateTime(String formatString, List(Int32) timeComponents)
Returns a formatted string including the given date.
Parameters:
- formatString - format string where the following specifiers are allowed:
%A : Full name of the day of the week (e.g., Tuesday)
%B : Full name of the month of the year (e.g., March)
%H : Two-digit 24-hour clock (in the range [00:23])
%I : Two-digit 12-hour clock (in the range [00:11])
%M : Minute within the hour (two-digits, in the range [00:59])
%S : Second within the minute (two-digits, in the range [00:59])
%Y : Year in four digits (in the range [1:9999])
%a : Short name of the day of the week (e.g., Tue)
%b : Short name of the month of the year (e.g., Mar)
%d : Day of the month (two-digits, in the range [01:31])
%j : Day of the year (three-digits, in the range [001:366])
%m : Month of the year (two-digits, in the range [01:12])
%p : Morning/afternoon marker (AM or PM)
- %yLast two digits of the year (in the range [00:99])
-
(non-nullable).
- timeComponents - the date-time components of the form: [year, month, mday, hour, minute, second, wday, yday, isdst]
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise (non-nullable, null elements not allowed).
Returns:
a formatted time string.
time.fractionalDaysToHours
<Numeric T> Double time.fractionalDaysToHours(T days)
Converts the time duration given in days to hours (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of hours (days x hours in a day = days x 24).
time.fractionalDaysToMicros
<Numeric T> Double time.fractionalDaysToMicros(T days)
Converts the time duration given in days to microseconds (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of microseconds (days x (micros in a day) = days x (24 x 60 x 60 x 1000 x 1000)).
time.fractionalDaysToMillis
<Numeric T> Double time.fractionalDaysToMillis(T days)
Converts the time duration given in days to milliseconds (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (days x (millis in a day) = days x (24 x 60 x 60 x 1000)).
time.fractionalDaysToMinutes
<Numeric T> Double time.fractionalDaysToMinutes(T days)
Converts the time duration given in days to minutes (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of minutes (days x (minutes in a day) = days x (24 x 60)).
time.fractionalDaysToNanos
<Numeric T> Double time.fractionalDaysToNanos(T days)
Converts the time duration given in days to nanoseconds (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (days x (nanos in a day) = days x (24 x 60 x 60 x 1000 x 1000 x 1000)).
time.fractionalDaysToSeconds
<Numeric T> Double time.fractionalDaysToSeconds(T days)
Converts the time duration given in days to seconds (in fractional form).
Parameters:
- days - the time duration given in days (non-nullable).
Returns:
the time duration expressed in terms of seconds (days x (seconds in a day) = days x (24 x 60 x 60)).
time.fractionalHoursToDays
<Numeric T> Double time.fractionalHoursToDays(T hours)
Converts the time duration given in hours to days (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of days (one 24th of hours).
time.fractionalHoursToMicros
<Numeric T> Double time.fractionalHoursToMicros(T hours)
Converts the time duration given in hours to microseconds (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of microseconds (hours x (micros in an hour) = hours x (60 x 60 x 1000 x 1000)).
time.fractionalHoursToMillis
<Numeric T> Double time.fractionalHoursToMillis(T hours)
Converts the time duration given in hours to milliseconds (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (hours x millis in an hour = hours x (60 x 60 x 1000)).
time.fractionalHoursToMinutes
<Numeric T> Double time.fractionalHoursToMinutes(T hours)
Converts the time duration given in hours to minutes (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of minutes (hours x minutes in an hour = hours x 60).
time.fractionalHoursToNanos
<Numeric T> Double time.fractionalHoursToNanos(T hours)
Converts the time duration given in hours to nanoseconds (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (hours x (nanos in an hour) = hours x (60 x 60 x 1000 x 1000 x 1000)).
time.fractionalHoursToSeconds
<Numeric T> Double time.fractionalHoursToSeconds(T hours)
Converts the time duration given in hours to seconds (in fractional form).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of seconds (hours x (seconds in an hour) = hours x (60 x 60)).
time.fractionalMicrosToDays
<Numeric T> Double time.fractionalMicrosToDays(T micros)
Converts the time duration given in microseconds to days (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of days (micros / (micros in a day) = micros / (24 x 60 x 60 x 1000 x 1000)).
time.fractionalMicrosToHours
<Numeric T> Double time.fractionalMicrosToHours(T micros)
Converts the time duration given in microseconds to hours (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (micros / (micros in an hour) = micros / (60 x 60 x 1000 x 1000)).
time.fractionalMicrosToMillis
<Numeric T> Double time.fractionalMicrosToMillis(T micros)
Converts the time duration given in microseconds to milliseconds (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (micros / micros in a millisecond = micros / 1000).
time.fractionalMicrosToMinutes
<Numeric T> Double time.fractionalMicrosToMinutes(T micros)
Converts the time duration given in microseconds to minutes (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (micros / (micros in a minute) = micros / (60 x 1000 x 1000)).
time.fractionalMicrosToNanos
<Numeric T> Double time.fractionalMicrosToNanos(T micros)
Converts the time duration given in microseconds to nanoseconds (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (micros x nanos in a microsecond = micros x 1000).
time.fractionalMicrosToSeconds
<Numeric T> Double time.fractionalMicrosToSeconds(T micros)
Converts the time duration given in microseconds to seconds (in fractional form).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (micros / (micros in a second) = micros / (1000 x 1000)).
time.fractionalMillisToDays
<Numeric T> Double time.fractionalMillisToDays(T millis)
Converts the time duration given in milliseconds to days (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of days (millis / (millis in a day) = millis / (24 x 60 x 60 x 1000)).
time.fractionalMillisToHours
<Numeric T> Double time.fractionalMillisToHours(T millis)
Converts the time duration given in milliseconds to hours (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (millis / (millis in an hour) = millis / (60 x 60 x 1000)).
time.fractionalMillisToMicros
<Numeric T> Double time.fractionalMillisToMicros(T millis)
Converts the time duration given in milliseconds to microseconds (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (millis x micros in a millisecond = millis x 1000).
time.fractionalMillisToMinutes
<Numeric T> Double time.fractionalMillisToMinutes(T millis)
Converts the time duration given in milliseconds to minutes (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (millis / (millis in a minute) = millis / (60 x 1000)).
time.fractionalMillisToNanos
<Numeric T> Double time.fractionalMillisToNanos(T millis)
Converts the time duration given in milliseconds to nanoseconds (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (millis x (nanos in a millisecond) = millis x (1000 x 1000)).
time.fractionalMillisToSeconds
<Numeric T> Double time.fractionalMillisToSeconds(T millis)
Converts the time duration given in milliseconds to seconds (in fractional form).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (millis / millis in a second = millis / 1000).
time.fractionalMinutesToDays
<Numeric T> Double time.fractionalMinutesToDays(T minutes)
Converts the time duration given in minutes to days (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of days (minutes / (minutes in a day) = minutes / (24 x 60)).
time.fractionalMinutesToHours
<Numeric T> Double time.fractionalMinutesToHours(T minutes)
Converts the time duration given in minutes to hours (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of hours (minutes / minutes in an hour = minutes / 60).
time.fractionalMinutesToMicros
<Numeric T> Double time.fractionalMinutesToMicros(T minutes)
Converts the time duration given in minutes to microseconds (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of microseconds (minutes x (micros in a minute) = minutes x (60 x 1000 x 1000)).
time.fractionalMinutesToMillis
<Numeric T> Double time.fractionalMinutesToMillis(T minutes)
Converts the time duration given in minutes to milliseconds (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (minutes x (millis in a minute) = minutes x (60 x 1000)).
time.fractionalMinutesToNanos
<Numeric T> Double time.fractionalMinutesToNanos(T minutes)
Converts the time duration given in minutes to nanoseconds (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (minutes x (nanos in a minute) = minutes x (60 x 1000 x 1000 x 1000)).
time.fractionalMinutesToSeconds
<Numeric T> Double time.fractionalMinutesToSeconds(T minutes)
Converts the time duration given in minutes to seconds (in fractional form).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of seconds (minutes x seconds in a minute = minutes x 60).
time.fractionalNanosToDays
<Numeric T> Double time.fractionalNanosToDays(T nanos)
Converts the time duration given in nanoseconds to days (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of days (nanos / (nanos in a day) = nanos / (24 x 60 x 60 x 1000 x 1000 x 1000)).
time.fractionalNanosToHours
<Numeric T> Double time.fractionalNanosToHours(T nanos)
Converts the time duration given in nanoseconds to hours (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (nanos / (nanos in an hour) = nanos / (60 x 60 x 1000 x 1000 x 1000)).
time.fractionalNanosToMicros
<Numeric T> Double time.fractionalNanosToMicros(T nanos)
Converts the time duration given in nanoseconds to microseconds (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (nanos / nanos in a microsecond = nanos / 1000).
time.fractionalNanosToMillis
<Numeric T> Double time.fractionalNanosToMillis(T nanos)
Converts the time duration given in nanoseconds to milliseconds (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (nanos / (nanos in an millisecond) = nanos / (1000 x 1000)).
time.fractionalNanosToMinutes
<Numeric T> Double time.fractionalNanosToMinutes(T nanos)
Converts the time duration given in nanoseconds to minutes (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (nanos / (nanos in a minute) = nanos / (60 x 1000 x 1000 x 1000)).
time.fractionalNanosToSeconds
<Numeric T> Double time.fractionalNanosToSeconds(T nanos)
Converts the time duration given in nanoseconds to seconds (in fractional form).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (nanos / (nanos in a second) = nanos / (1000 x 1000 x 1000)).
time.fractionalSecondsToDays
<Numeric T> Double time.fractionalSecondsToDays(T seconds)
Converts the time duration given in seconds to days (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of days (seconds / (seconds in a day) = seconds / (24 x 60 x 60)).
time.fractionalSecondsToHours
<Numeric T> Double time.fractionalSecondsToHours(T seconds)
Converts the time duration given in seconds to hours (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of hours (seconds / (seconds in an hour) = seconds / (60 x 60)).
time.fractionalSecondsToMicros
<Numeric T> Double time.fractionalSecondsToMicros(T seconds)
Converts the time duration given in seconds to microseconds (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (seconds x (micros in a second) = seconds x (1000 x 1000)).
time.fractionalSecondsToMillis
<Numeric T> Double time.fractionalSecondsToMillis(T seconds)
Converts the time duration given in seconds to milliseconds (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (seconds x millis in a second = seconds x 1000).
time.fractionalSecondsToMinutes
<Numeric T> Double time.fractionalSecondsToMinutes(T seconds)
Converts the time duration given in seconds to minutes (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (seconds / seconds in a minute = seconds / 60).
time.fractionalSecondsToNanos
<Numeric T> Double time.fractionalSecondsToNanos(T seconds)
Converts the time duration given in seconds to nanoseconds (in fractional form).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (seconds x (nanos in a second) = seconds x (1000 x 1000 x 1000)).
time.hoursToDays
<Integral T> Int64 time.hoursToDays(T hours)
Converts the time duration given in hours to days (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of days (one 24th of hours - integer division).
time.hoursToMicros
<Integral T> Int64 time.hoursToMicros(T hours)
Converts the time duration given in hours to microseconds (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of microseconds (hours x (micros in an hour) = hours x (60 x 60 x 1000 x 1000)).
time.hoursToMillis
<Integral T> Int64 time.hoursToMillis(T hours)
Converts the time duration given in hours to milliseconds (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (hours x millis in an hour = hours x (60 x 60 x 1000)).
time.hoursToMinutes
<Integral T> Int64 time.hoursToMinutes(T hours)
Converts the time duration given in hours to minutes (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of minutes (hours x minutes in an hour = hours x 60).
time.hoursToNanos
<Integral T> Int64 time.hoursToNanos(T hours)
Converts the time duration given in hours to nanoseconds (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (hours x (nanos in an hour) = hours x (60 x 60 x 1000 x 1000 x 1000)).
time.hoursToSeconds
<Integral T> Int64 time.hoursToSeconds(T hours)
Converts the time duration given in hours to seconds (as integer).
Parameters:
- hours - the time duration given in hours (non-nullable).
Returns:
the time duration expressed in terms of seconds (hours x (seconds in an hour) = hours x (60 x 60)).
time.localDateTimeFromDate
List(Int32) time.localDateTimeFromDate(Int32 year, Int32 month, Int32 day)
Produces the local date-time components ([year, month, mday, hour, minute, second, wday, yday, isdst]) according to the given date information (year, month and day)
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- year - year (in the range [1:9999]) (non-nullable).
- month - month (in the range [1:12]) (non-nullable).
- day - the day of the month (in the range [1:31]) (non-nullable).
Returns:
the local date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].
time.localDateTimeFromDateTime
List(Int32) time.localDateTimeFromDateTime(Int32 year, Int32 month, Int32 day, Int32 hour, Int32 minute, Int32 second)
Produces the local date-time components ([year, month, mday, hour, minute, second, wday, yday, isdst]) according to the given date and time information (year, month, day, hour, minute and second)
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- year - the year (in the range [1:9999]) (non-nullable).
- month - the month within the year (in the range [1:12]) (non-nullable).
- day - the day within the month (in the range [1:31]) (non-nullable).
- hour - the hour within the day (in the range [0:23]) (non-nullable).
- minute - the minute within the hour (in the range [0:59]) (non-nullable).
- second - the second within the minute (in the range [0:59]) (non-nullable).
Returns:
the local date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].
time.localTime
List(Int32) time.localTime(Double value)
Converts the time in seconds since the Epoch to the local date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst]
year: Year as a decimal
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- value - the time (fractional seconds since the Epoch) (non-nullable).
Returns:
the local date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].
time.microsToDays
<Integral T> Int64 time.microsToDays(T micros)
Converts the time duration given in microseconds to days (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of days (micros / (micros in a day) = micros / (24 x 60 x 60 x 1000 x 1000) - integer division).
time.microsToHours
<Integral T> Int64 time.microsToHours(T micros)
Converts the time duration given in microseconds to hours (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (micros / (micros in an hour) = micros / (60 x 60 x 1000 x 1000) - integer division).
time.microsToMillis
<Integral T> Int64 time.microsToMillis(T micros)
Converts the time duration given in microseconds to milliseconds (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (micros / micros in a millisecond = micros / 1000 - integer division).
time.microsToMinutes
<Integral T> Int64 time.microsToMinutes(T micros)
Converts the time duration given in microseconds to minutes (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (micros / (micros in a minute) = micros / (60 x 1000 x 1000) - integer division).
time.microsToNanos
<Integral T> Int64 time.microsToNanos(T micros)
Converts the time duration given in microseconds to nanoseconds (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (micros x nanos in a microsecond = micros x 1000).
time.microsToSeconds
<Integral T> Int64 time.microsToSeconds(T micros)
Converts the time duration given in microseconds to seconds (as integer).
Parameters:
- micros - the time duration given in microseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (micros / (micros in a second) = micros / (1000 x 1000) - integer division).
time.millisToDays
<Integral T> Int64 time.millisToDays(T millis)
Converts the time duration given in milliseconds to days (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of days (millis / (millis in a day) = millis / (24 x 60 x 60 x 1000) - integer division).
time.millisToHours
<Integral T> Int64 time.millisToHours(T millis)
Converts the time duration given in milliseconds to hours (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (millis / (millis in an hour) = millis / (60 x 60 x 1000) - integer division).
time.millisToMicros
<Integral T> Int64 time.millisToMicros(T millis)
Converts the time duration given in milliseconds to microseconds (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (millis x micros in a millisecond = millis x 1000).
time.millisToMinutes
<Integral T> Int64 time.millisToMinutes(T millis)
Converts the time duration given in milliseconds to minutes (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (millis / (millis in a minute) = millis / (60 x 1000) - integer division).
time.millisToNanos
<Integral T> Int64 time.millisToNanos(T millis)
Converts the time duration given in milliseconds to nanoseconds (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (millis x (nanos in a millisecond) = millis x (1000 x 1000)).
time.millisToSeconds
<Integral T> Int64 time.millisToSeconds(T millis)
Converts the time duration given in milliseconds to seconds (as integer).
Parameters:
- millis - the time duration given in milliseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (millis / millis in a second = millis / 1000 - integer division).
time.minutesToDays
<Integral T> Int64 time.minutesToDays(T minutes)
Converts the time duration given in minutes to days (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of days (minutes / (minutes in a day) = minutes / (24 x 60) - integer division).
time.minutesToHours
<Integral T> Int64 time.minutesToHours(T minutes)
Converts the time duration given in minutes to hours (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of hours (minutes / minutes in an hour = minutes / 60 - integer division).
time.minutesToMicros
<Integral T> Int64 time.minutesToMicros(T minutes)
Converts the time duration given in minutes to microseconds (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of microseconds (minutes x (micros in a minute) = minutes x (60 x 1000 x 1000)).
time.minutesToMillis
<Integral T> Int64 time.minutesToMillis(T minutes)
Converts the time duration given in minutes to milliseconds (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (minutes x (millis in a minute) = minutes x (60 x 1000)).
time.minutesToNanos
<Integral T> Int64 time.minutesToNanos(T minutes)
Converts the time duration given in minutes to nanoseconds (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (minutes x (nanos in a minute) = minutes x (60 x 1000 x 1000 x 1000)).
time.minutesToSeconds
<Integral T> Int64 time.minutesToSeconds(T minutes)
Converts the time duration given in minutes to seconds (as integer).
Parameters:
- minutes - the time duration given in minutes (non-nullable).
Returns:
the time duration expressed in terms of seconds (minutes x seconds in a minute = minutes x 60).
time.nanosToDays
<Integral T> Int64 time.nanosToDays(T nanos)
Converts the time duration given in nanoseconds to days (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of days (nanos / (nanos in a day) = nanos / (24 x 60 x 60 x 1000 x 1000 x 1000) - integer division).
time.nanosToHours
<Integral T> Int64 time.nanosToHours(T nanos)
Converts the time duration given in nanoseconds to hours (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of hours (nanos / (nanos in an hour) = nanos / (60 x 60 x 1000 x 1000 x 1000) - integer division).
time.nanosToMicros
<Integral T> Int64 time.nanosToMicros(T nanos)
Converts the time duration given in nanoseconds to microseconds (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (nanos / nanos in a microsecond = nanos / 1000 - integer division).
time.nanosToMillis
<Integral T> Int64 time.nanosToMillis(T nanos)
Converts the time duration given in nanoseconds to milliseconds (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (nanos / (nanos in an millisecond) = nanos / (1000 x 1000) - integer division).
time.nanosToMinutes
<Integral T> Int64 time.nanosToMinutes(T nanos)
Converts the time duration given in nanoseconds to minutes (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (nanos / (nanos in a minute) = nanos / (60 x 1000 x 1000 x 1000) - integer division).
time.nanosToSeconds
<Integral T> Int64 time.nanosToSeconds(T nanos)
Converts the time duration given in nanoseconds to seconds (as integer).
Parameters:
- nanos - the time duration given in nanoseconds (non-nullable).
Returns:
the time duration expressed in terms of seconds (nanos / (nanos in a second) = nanos / (1000 x 1000 x 1000) - integer division).
time.parseLocalDateTime
List(Int32) time.parseLocalDateTime(String dateTimeString, String formatString)
Produces the date-time components of a local date-time string according to the given format.
Parameters:
- dateTimeString - a local date-time string (non-nullable).
- formatString - a format string where the following specifiers are allowed:
%A : Full name of the day of the week (e.g., Tuesday)
%B : Full name of the month of the year (e.g., March)
%H : Two-digit 24-hour clock (in the range [00:23])
%I : Two-digit 12-hour clock (in the range [00:11])
%M : Minute within the hour (two-digits, in the range [00:59])
%S : Second within the minute (two-digits, in the range [00:59])
%Y : Year in four digits (in the range [1:9999])
%a : Short name of the day of the week (e.g., Tue)
%b : Short name of the month of the year (e.g., Mar)
%d : Day of the month (two-digits, in the range [01:31])
%j : Day of the year (three-digits, in the range [001:366])
%m : Month of the year (two-digits, in the range [01:12])
%p : Morning/afternoon marker (AM or PM)
- %yLast two digits of the year (in the range [00:99])
-
(non-nullable).
Returns:
the date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst]
year: Year as a decimal
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
time.parseUtcDateTime
List(Int32) time.parseUtcDateTime(String dateTimeString, String formatString)
Produces the date-time components of a UTC date-time string according to the given format.
Parameters:
- dateTimeString - a UTC date-time string (non-nullable).
- formatString - a format string where the following specifiers are allowed:
%A : Full name of the day of the week (e.g., Tuesday)
%B : Full name of the month of the year (e.g., March)
%H : Two-digit 24-hour clock (in the range [00:23])
%I : Two-digit 12-hour clock (in the range [00:11])
%M : Minute within the hour (two-digits, in the range [00:59])
%S : Second within the minute (two-digits, in the range [00:59])
%Y : Year in four digits (in the range [1:9999])
%a : Short name of the day of the week (e.g., Tue)
%b : Short name of the month of the year (e.g., Mar)
%d : Day of the month (two-digits, in the range [01:31])
%j : Day of the year (three-digits, in the range [001:366])
%m : Month of the year (two-digits, in the range [01:12])
%p : Morning/afternoon marker (AM or PM)
- %yLast two digits of the year (in the range [00:99])
-
(non-nullable).
Returns:
the date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst]
year: Year as a decimal
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
time.secondsToDays
<Integral T> Int64 time.secondsToDays(T seconds)
Converts the time duration given in seconds to days (as integer).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of days (seconds / (seconds in a day) = seconds / (24 x 60 x 60) - integer division).
time.secondsToHours
<Integral T> Int64 time.secondsToHours(T seconds)
Converts the time duration given in seconds to hours (as integer).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of hours (seconds / (seconds in an hour) = seconds / (60 x 60) - integer division).
time.secondsToMicros
<Integral T> Int64 time.secondsToMicros(T seconds)
Converts the time duration given in seconds to microseconds (as integer).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of microseconds (seconds x (micros in a second) = seconds x (1000 x 1000)).
time.secondsToMillis
<Integral T> Int64 time.secondsToMillis(T seconds)
Converts the time duration given in seconds to milliseconds (as integer).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of milliseconds (seconds x millis in a second = seconds x 1000).
time.secondsToMinutes
<Integral T> Int64 time.secondsToMinutes(T seconds)
Converts the time duration given in seconds to minutes (as integer).
Parameters:
- seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of minutes (seconds / seconds in a minute = seconds / 60 - integer division).
time.secondsToNanos
<Integral T> Int64 time.secondsToNanos(T seconds)
Converts the time duration given in seconds to nanoseconds (as integer).
Parameters:
-
seconds - the time duration given in seconds (non-nullable).
Returns:
the time duration expressed in terms of nanoseconds (seconds x (nanos in a second) = seconds x (1000 x 1000 x 1000)).
time.utcDateTimeFromDate
List(Int32) time.utcDateTimeFromDate(Int32 year, Int32 month, Int32 day)
Produces the UTC date-time components ([year, month, mday, hour, minute, second, wday, yday, isdst]) according to the given date information (year, month and day)
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- year - year (in the range [1:9999]) (non-nullable).
- month - month (in the range [1:12]) (non-nullable).
-
day - the day of the month (in the range [1:31]) (non-nullable).
Returns:
the UTC date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].
time.utcDateTimeFromDateTime
List(Int32) time.utcDateTimeFromDateTime(Int32 year, Int32 month, Int32 day, Int32 hour, Int32 minute, Int32 second)
Produces the UTC date-time components ([year, month, mday, hour, minute, second, wday, yday, isdst]) according to the given date and time information (year, month, day, hour, minute and second)
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- year - the year (in the range [1:9999]) (non-nullable).
- month - the month within the year (in the range [1:12]) (non-nullable).
- day - the day within the month (in the range [1:31]) (non-nullable).
- hour - the hour within the day (in the range [0:23]) (non-nullable).
- minute - the minute within the hour (in the range [0:59]) (non-nullable).
- second - the second within the minute (in the range [0:59]) (non-nullable).
Returns:
the UTC date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].
time.utcTime
List(Int32) time.utcTime(Double value)
Converts the time in seconds since the Epoch to the UTC date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst]
year: Year as a decimal number
month: Month, in the range [1:12]
mday: Day of the month, in the range [1:31]
hour: Hours, in the range [0:23]
minute: Minutes, in the range [0:59]
second: Seconds, in the range [0:59]
wday: Day of the week, in the range [0:6], Monday is 0
yday: Day of the year, in the range [1:366]
isdst: 1 if daylight saving time is in effect, 0 otherwise.
Parameters:
- value - the time (fractional seconds since the Epoch) (non-nullable).
Returns:
the UTC date-time components in the format: [year, month, mday, hour, minute, second, wday, yday, isdst].