Starts to lookup.
@param  {Number}   interval The interval milliseconds. [optional]
@param  {Function} callback The function, that will be called when trigger has started. [optional]
`function(err){}`
549926
function(interval, callback) {
    if (lookupIntervalId) {
      return;
    }

    isRunning = true;

    if (!callback && _.isFunction(interval)) {
      callback = interval;
      interval = null;
    }

    interval = interval || 500;

    globalSerialDeviceLoader.trigger(function(err) {
      var triggering = false;
      lookupIntervalId = setInterval(function() {
        if (triggering) return;
        triggering = true;
        globalSerialDeviceLoader.trigger(function() {
          triggering = false;
        });
      }, interval);

      if (err && !err.name) {
        err = new Error(err);
      }
      if (callback) { callback(err); }
    });
  }
1024757
void setInterval(String interval) {

        final int i = CmsSerialDateUtil.toIntWithDefault(interval, -1);
        if (m_model.getInterval() != i) {
            removeExceptionsOnChange(new Command() {

                public void execute() {

                    m_model.setInterval(i);
                    onValueChange();
                }
            });
        }

    }
665895
public void scheduleAtWithInterval(final org.easybatch.core.job.Job job, final Date startTime, final int interval) throws JobSchedulerException {
        checkNotNull(job, "job");
        checkNotNull(startTime, "startTime");

        String name = job.getName();
        String jobName = JOB_NAME_PREFIX + name;
        String triggerName = TRIGGER_NAME_PREFIX + name;

        SimpleScheduleBuilder scheduleBuilder = simpleSchedule()
                .withIntervalInSeconds(interval)
                .repeatForever();

        Trigger trigger = newTrigger()
                .withIdentity(triggerName)
                .startAt(startTime)
                .withSchedule(scheduleBuilder)
                .forJob(jobName)
                .build();

        JobDetail jobDetail = getJobDetail(job, jobName);

        try {
            LOGGER.info("Scheduling job ''{}'' to start at {} and every {} second(s)", name, startTime, interval);
            scheduler.scheduleJob(jobDetail, trigger);
        } catch (SchedulerException e) {
            throw new JobSchedulerException(format("Unable to schedule job '%s'", name), e);
        }
    }
964370
function intervalStuff() {

    var message = "doing interval stuff at " + new Date()

    // add a timeout
    setTimeout(function() { console.log(message)}, 333)

    // add a timeline marker
    console.markTimeline(message)

    // write to local- and sessionStorage
    if (window.localStorage) {
        var smessage = message + " (local)"
        window.localStorage.setItem(  "item-" + storageIndex, smessage)
    }

    if (window.sessionStorage) {
        var smessage = message + " (session)"
        window.sessionStorage.setItem("item-" + storageIndex, smessage)
    }
    storageIndex++

    // write the message to the page
    output(message)

    // do an XHR
    var xhr = new XMLHttpRequest()
    // xhr.addEventListener("readystatechange", function() {logXhr(this)})
    xhr.open("GET", "../target/target-script.js", true)
    xhr.send()
}
625389
function startCheckingArpTable() {
    setInterval(()=>{
        chkArpTable();
        for (const macinfo of Object.values(macs)) {
            pingNet(macinfo.net, macinfo.ip);
        }
    }, CHECK_ARP_TABLE_AND_PING_INTERVAL);
    // Initial check
    chkArpTable();
}
204117
function(callback){
        for(this._itr; this._itr < this._data.length; this._itr++) {
            this._testFunction.call(this, this._itr);
        }

        callback.call(this, this._res);
	}
951230
function AnyTimer(fn, timeval, isInterval) {
	this.clear = clear
	var isClear
	if (!(timeval >= 1)) timeval = 1 // ensure number
	var baseTime = Date.now()
	var nextTargetTime = baseTime + timeval
	var timer
	var interval

	if (isInterval && timeval <= TIMEOUT_MAX) { // this actually works with setInterval
		interval = setInterval(fn, timeval)
	} else timerFire()

	function timerFire() {
		var remaining = nextTargetTime - Date.now()
		if (remaining <= 0) {
			timer = null
			fn()
			if (isInterval && !isClear) {
				nextTargetTime += isInterval
				setTimer(nextTargetTime - Date.now())
			}
		} else setTimer(remaining)
	}

	function setTimer(remaining) {
		if (remaining >= time1day) remaining = time1day
		timer = setTimeout(timerFire, remaining)
	}

	function clear() {
		isClear = true
		if (timer) {
			var t = timer
			timer = null
			clearTimeout(t)
		}
		if (interval) {
			var i = interval
			interval = null
			clearInterval(i)
		}
	}
}
947555
function(that) {
    if (this.sourceString !== that.sourceString) {
      throw errors.intervalSourcesDontMatch();
    }
    assert(this.startIdx >= that.startIdx && this.endIdx <= that.endIdx,
           'other interval does not cover this one');
    return new Interval(this.sourceString,
                        this.startIdx - that.startIdx,
                        this.endIdx - that.startIdx);
  }
1306032
function  () {
        if (this._intervalId) {
            clearInterval(this._intervalId);
            this._intervalId = undefined;
            this.trigger(this.options.stoppedEventName, this);
            return true;
        }
        return false;
    }
881110
function() {
    var contents = this.contents;
    var startIdx = this.startIdx + contents.match(/^\s*/)[0].length;
    var endIdx = this.endIdx - contents.match(/\s*$/)[0].length;
    return new Interval(this.sourceString, startIdx, endIdx);
  }
1088624
function(options){
    this.triggerMethod("initialize:before", options);
    this._initCallbacks.run(options, this);
    this.triggerMethod("initialize:after", options);

    this.triggerMethod("start", options);
  }
430981
function(callback) {

      // Detect server errors
      var t = this, server = t.get('server');
      server.on('clientError', function(err){
        console.error('Client error detected on server', err);
        t.trigger('error', err);
      });
      server.on('close', function(err){
        server.hasEmittedClose = true;
        t.stop();
      });

      // Notify that we've started
      t.isListening = true;
      if (callback) {
        callback(null);
      }
      t.trigger('start');
    }
29621
public void setInterval(ReadableInterval interval) {
        if (interval == null) {
            throw new IllegalArgumentException("Interval must not be null");
        }
        long startMillis = interval.getStartMillis();
        long endMillis = interval.getEndMillis();
        Chronology chrono = interval.getChronology();
        super.setInterval(startMillis, endMillis, chrono);
    }
1070136
def _start(self):
        """"""

        # TODO : make an update method instead

        last_call = 42
        while self._focus:
            sleep(1 / 100)

            mouse = pygame.mouse.get_pos()
            last_value = self.get()
            self.value_px = mouse[0]

            # we do not need to do anything when it the same value
            if self.get() == last_value:
                continue

            if last_call + self.interval / 1000 < time():
                last_call = time()
                self.func(self.get())
543119
public void start(IStore store, int interval) {
        synchronized (this) {
            _invalInterval = interval;
            _timer = new Timer(true);
            _invalTask = new InvalidationTask(store);
            _timer.schedule(_invalTask, _delay * 1000, _invalInterval * 1000);
        }
    }
1092180
function backgroundRefreshInit(){
    if(!backgroundRefreshEnabled){
      backgroundRefreshEnabled = true;
      if(self.backgroundRefreshIntervalCheck){
        if(self.backgroundRefreshInterval > self.backgroundRefreshMinTtl){
          throw new Exception('BACKGROUND_REFRESH_INTERVAL_EXCEPTION', 'backgroundRefreshInterval cannot be greater than backgroundRefreshMinTtl.');
        }
      }
      setInterval(function(){
        backgroundRefresh();
      }, self.backgroundRefreshInterval);
    }
  }
1067927
function(callback, err) {
    if (err) {
      if (callback) callback(err);
      return;
    }

    var duration = new Date().getTime() - this.start;
    this.logger.log('Done in ' + duration + 'ms.');

    if (callback) callback();
  }