See EventTarget.addEventListener for reference. Works with EventListenerUnified and EventUnified
Optional_options: boolean | AddEventListenerOptionsStops and deletes all Timers attached. Should be called before this Time-object leaves scope
Returns a Promise
Deletes the timer with the id given by this time object
Deletes Timer found using the internal id of the connected interval-object
See EventTarget.dispatchEvent for reference. Works with with EventUnified
Retrieves the current scaled timestamp of this instance in milliseconds
Retrieves the scaled time in milliseconds passed since the last call to this method Automatically reset at every call to set(...) and setScale(...)
Retrieves the offset of this time
Returns the remaining time to the given point of time
Retrieves the current scaling of this time
Returns a reference to the timer with the given id or null if not found.
Returns a copy of the list of timers currently installed on this time object
Returns true if there are Timers installed to this
See EventTarget.removeEventListener for reference. Works with EventListenerUnified and EventUnified
Optional_options: boolean | AddEventListenerOptions(Re-) Sets the timestamp of this instance
The timestamp to represent the current time (default 0.0)
Sets the scaling of this time, allowing for slowmotion (<1) or fastforward (>1)
The desired scaling (default 1.0)
Installs a timer at this time object
The object-time to elapse between the calls to _callback
The number of calls desired, 0 = Infinite
The function to call each the given lapse has elapsed
Additional parameters to pass to callback function
Staticget
Instances of this class generate a timestamp that correlates with the time elapsed since the start of the program but allows for resetting and scaling.
Supports Timers similar to window.setInterval but with respect to the scaled time. All time values are given in milliseconds
Authors
Jirka Dell'Oro-Friedl, HFU, 2019