Called whenever the appropriate interval has passed and the stats should be updated.
177193
public void update(){
		if (tieable.isActivated()){
			return;
		}
		for (IStats s : producer.getStats()) {
			if (s.getName().equals(tieable.getTargetStatName())) {
				tieable.tieToStats(s);
				tieable.update();
				return;
			}
		}
	}
787391
synchronized void statusUpdate(State runState, 
                                 float progress,
                                 String state, 
                                 Phase phase,
                                 long finishTime) {
    setRunState(runState);
    setProgress(progress);
    setStateString(state);
    setPhase(phase);
    if (finishTime > 0) {
      setFinishTime(finishTime); 
    }
  }
1145648
def _needs_update(self):
        ''

        if self.poll_interval:
            delta = timeit.default_timer() - self._last_update_timer
            poll_status = delta > self.poll_interval.total_seconds()
        else:
            delta = 0
            poll_status = False

        # Do not update if value increment is not large enough to
        # add more bars to progressbar (according to current
        # terminal width)
        try:
            divisor = self.max_value / self.term_width  # float division
            if self.value // divisor == self.previous_value // divisor:
                return poll_status or self.end_time
            else:
                return True
        except Exception:
            # ignore any division errors
            pass

        return poll_status or self.end_time
515385
private synchronized void refresh() {

        try {
            long now = System.currentTimeMillis();
            if ((now - m_lastUpdate) > UPDATE_INTERVAL) {
                setup();
            }
        } catch (CmsException e) {
            LOG.error(e.getLocalizedMessage(), e);
        }
    }
127927
private void handleChangeCleaningInterval(final HttpServletRequest req,
      final Map<String, Object> ret) {
    try {
      final long newInterval = getLongParam(req, STATS_MAP_CLEANINGINTERVAL);
      if (MetricReportManager.isAvailable()) {
        final MetricReportManager metricManager = MetricReportManager.getInstance();
        final InMemoryMetricEmitter memoryEmitter =
            extractInMemoryMetricEmitter(metricManager);
        memoryEmitter.setReportingInterval(newInterval);
        ret.put(STATUS_PARAM, RESPONSE_SUCCESS);
      } else {
        ret.put(RESPONSE_ERROR, "MetricManager is not available");
      }
    } catch (final Exception e) {
      logger.error(e);
      ret.put(RESPONSE_ERROR, e.getMessage());
    }
  }
1123159
private void updateInterval() {
        intervalMillis = getCombinedValue(endDate, endTime) - getCombinedValue(startDate, startTime);
        
        // if this is zero, most likely the times aren't set and the
        // dates are the same. in this case we don't really want a
        // zero interval. if we *really* want a zero interval, the
        // default would be zero so this is safe.
        if (intervalMillis == 0) {
            intervalMillis = defaultIntervalMillis;
        }
    }
337718
def update_status(self, progress):
        

        # interval at which the gui will be updated, if requests come in faster than they will be ignored
        update_interval = 0.2

        now = datetime.datetime.now()

        if not self._last_progress_update is None and now-self._last_progress_update < datetime.timedelta(seconds=update_interval):
            return

        self._last_progress_update = now

        self.progressBar.setValue(progress)

        script = self.current_script

        # Estimate remaining time if progress has been made
        if progress:
            remaining_time = str(datetime.timedelta(seconds=script.remaining_time.seconds))
            self.lbl_time_estimate.setText('time remaining: {:s}'.format(remaining_time))
        if script is not str(self.tabWidget.tabText(self.tabWidget.currentIndex())).lower() in ['scripts', 'instruments']:
            self.plot_script(script)
618090
def update(self):
        """"""
        # Init new stats
        stats = self.get_init_value()

        if self.input_method == 'local':
            # Update stats using the standard system lib
            self.uptime = datetime.now() - datetime.fromtimestamp(psutil.boot_time())

            # Convert uptime to string (because datetime is not JSONifi)
            stats = str(self.uptime).split('.')[0]
        elif self.input_method == 'snmp':
            # Update stats using SNMP
            uptime = self.get_stats_snmp(snmp_oid=snmp_oid)['_uptime']
            try:
                # In hundredths of seconds
                stats = str(timedelta(seconds=int(uptime) / 100))
            except Exception:
                pass

        # Update the stats
        self.stats = stats

        return self.stats
786574
def update_trial_stats(self, trial, result):
        """"""

        assert trial in self._live_trials
        assert self._get_result_time(result) >= 0

        delta = self._get_result_time(result) - \
            self._get_result_time(self._live_trials[trial])
        assert delta >= 0
        self._completed_progress += delta
        self._live_trials[trial] = result
1102812
function (interval, user) {
		interval = interval || 2000;

		this._user = user || (new Date()).valueOf();
		this._need_update = false;
		//this._loader = null;
		this._update_busy = false;

		this.attachEvent("onAfterUpdate", function (sid, action, tid, xml_node) {
			this.afterAutoUpdate(sid, action, tid, xml_node);
		});
		this.attachEvent("onFullSync", function () {
			this.fullSync();
		});

		var self = this;
		window.setInterval(function () {
			self.loadUpdate();
		}, interval);
	}
1199136
private void updateTimeRange(long timestamp) {
        // update the timestamp ranges
        if (timestamp < startTime) {
            startTime = timestamp;
        } 
        if (timestamp > endTime) {
            endTime = timestamp;
        }
    }
861645
public function update($now)
    {
        if ($now >= ($this->lastCallTime + $this->interval)) {
            $this->lastCallTime = $now;
            $this->callNow();
        }
    }
284255
def update(self):
        """"""
        # Had to convert it to string because datetime is not JSON serializable
        self.stats = datetime.now().strftime('%Y-%m-%d %H:%M:%S')
        # Add the time zone (issue #1249 and issue #1337)
        if 'tmzone' in localtime():
            self.stats += ' {}'.format(localtime().tm_zone)
        elif len(tzname) > 0:
            self.stats += ' {}'.format(tzname[1])

        return self.stats
273365
def update_continuously(records, update_interval=600):
    """"""
    while True:
        for record in records:
            try:
                record.update()
            except (ApiError, RequestException):
                pass
        time.sleep(update_interval)
1252604
def stats_timing(stats_key, stats_logger):
    """"""
    start_ts = now_as_float()
    try:
        yield start_ts
    except Exception as e:
        raise e
    finally:
        stats_logger.timing(stats_key, now_as_float() - start_ts)
466002
def update(self, stats):
        """"""

        if self.generate_every != 0 and self._timer.finished():
            self.args.generate_graph = True
            self._timer.reset()

        if not self.args.generate_graph:
            return

        plugins = stats.getPluginsList()
        for plugin_name in plugins:
            plugin = stats._plugins[plugin_name]
            if plugin_name in self.plugins_to_export():
                self.export(plugin_name, plugin.get_export_history())

        logger.info("Graphs created in the folder {}".format(self.path))
        self.args.generate_graph = False
368566
protected function updateTimestamps()
    {
        if ($this->parent->timestamps)
        {
            $time = $this->freshTimestamp();

            $this->setUpdatedAt($time);

            if ( ! $this->exists())
            {
                $this->setCreatedAt($time);
            }
        }
    }