Timer API

The Timer API helps you to schedule the execution of functions after configured time intervals.

The Timer API consists of the kony.timer namespace and the following API elements:

Function Description
kony.timer.cancel Cancels the timer that has already been scheduled for execution.
kony.timer.setCallBack Specifies the callback function that needs to be executed for a scheduled timer.
kony.timer.schedule Executes the given function after a specified interval of time.
 

Schedule the execution of functions using the kony.timer.schedule function. You can override the callback function of the scheduled timer and set a new callback function using the kony.timer.setCallBack function. Use the kony.timer.cancel function to cancel the execution of a scheduled timer.

To view the functionality of the Timer API in action, download the sample application from the link below. Once the application is downloaded, build and preview the application using the Quantum App.