UNPKG

scandit-web-datacapture-core

Version:

Scandit Data Capture SDK for the Web

4 lines (2 loc) 420 B
var t=class t{constructor(i,e){this._running=!1;this.duration=i>t.maxDurationAllowedByJSEngines?t.maxDurationAllowedByJSEngines:i,this.callback=e;}get running(){return this._running}start(){this.stop(),this.timeout=setTimeout(()=>{this.callback(),this.stop();},this.duration),this._running=!0;}stop(){clearTimeout(this.timeout),this._running=!1;}};t.maxDurationAllowedByJSEngines=2147483647;var n=t; export { n as a };