Contains classes for time related functions and objects.
await
method: pauses program for milisecondsawait @int:miliseconds
datetime
class:- Methods:
now
returns the current date and time as a string along with optional parameter to format itdatetime now : ? @str:format
utcnow
returns the utc date and time as a string along with optional parameter to format itdatetime utcnow : ? @str:format
today
returns today's date and time as a string along with optional parameter to format itdatetime today : ? @str:format
compare
returns1
,0
, or-1
depending on the dates relation to the other datedatetime compare : @str:time1, @str:time2
unixepoch
returns the unix epoch date and time as a string along with optional parameter to format itdatetime unixepoch : ? @str:format
max-value
returns the max value date and time as a string along with optional parameter to format itdatetime max-value : ? @str:format
min-value
returns the min value date and time as a string along with optional parameter to format itdatetime min-value : ? @str:format
days-in-month
returns the days in the month as an intdatetime days-int-month : @str:_time
is-leep-year
returns if the year is a leep yeardatetime is-leep-year : @str:_time
day-of-year
returns the day of the year as intdatetime day-of-year : @str:_time
day-of-week
returns the day of the week as strdatetime day-of-week : @str:_time
is-daylight-savings-time
returns if the year is in daylight savings timedatetime is-daylight-savings-time : @str:_time
- Methods:
stopwatch
class:- Methods:
start
starts a stopwatch instance that counts upend
ends the stopwatch in the instanceelapsed-nanoseconds
returns the elapsed nanoseconds from the stopwatch instanceelapsed-miliseconds
returns the elapsed miliseconds from the stopwatch instanceelapsed-seconds
returns the elapsed seconds from the stopwatch instanceelapsed-minutes
returns the elapsed minutes from the stopwatch instanceelapsed-hours
returns the elapsed hours from the stopwatch instance
- Methods:
timer
class:- Methods:
new-instance
returns a new instance of the timer class based off of the variable valuesnew-instance : @int:hours, @int:minutes, @int:seconds, @int:miliseconds
start
starts a timer with the values from the instance propertiesstop
stops the timer instanceresume
resumes the timer instanceis-done
returns if the timer instance has elapsedis-not-done
returns if the timer instance has not elapsed
- Properties:
hours
the timer instance's hoursminutes
the timer instance's minutesseconds
the timer instance's secondsmiliseconds
the timer instance's miliseconds
- Methods: