JavaScript:实现计时的单例类算法
/**
* @author Nandan V
* Sunday, 26 July 2020 8:33 AM
* @description Singleton class that handles the <b>timing of tests</b> and
* specs. <br/> The class is singleton as <u>javascript does not support
* multiple timer instances<u/>.
*/
class IntervalTimer {
/**
* @description Constructor for Timer.
* @param interval Sets the interval for running the timer.
* @param callBack The callback function to be executed.
* @return {IntervalTimer} If exists, the existing object.