Implement default delay mechanism.
548731
def _delay(self, ms):
        
        if ms:
            self.Delay(ms)
        else:
            if self.default_delay:
                self.Delay(self.default_delay)
133230
function() {
                        angular.forEach(pollers, function(p) {
                            p.delay = p.idleDelay;
                            if (angular.isDefined(p.interval)) {
                                p.restart();
                            }
                        });
                    }
268790
def delay(self, params, now=None):
        """"""

        if now is None:
            now = time.time()

        # Initialize last...
        if not self.last:
            self.last = now
        elif now < self.last:
            now = self.last

        # How much has leaked out?
        leaked = now - self.last

        # Update the last message time
        self.last = now

        # Update the water level
        self.level = max(self.level - leaked, 0)

        # Are we too full?
        difference = self.level + self.limit.cost - self.limit.unit_value
        if difference >= self.eps:
            self.next = now + difference
            return difference

        # OK, raise the water level and set next to an appropriate
        # value
        self.level += self.limit.cost
        self.next = now

        return None
1179632
public void add(long delay, T value) {
    mQueue.add(new DelayNode<>(value, delay + mPastTime));
  }
756667
public static void setToDefault ()
  {
    s_aRWLock.writeLocked ( () -> {
      s_nMaxMailQueueLen = DEFAULT_MAX_QUEUE_LENGTH;
      s_nMaxMailSendCount = DEFAULT_MAX_SEND_COUNT;
      s_bUseSSL = DEFAULT_USE_SSL;
      s_bUseSTARTTLS = DEFAULT_USE_STARTTLS;
      s_nConnectionTimeoutMilliSecs = DEFAULT_CONNECT_TIMEOUT_MILLISECS;
      s_nTimeoutMilliSecs = DEFAULT_TIMEOUT_MILLISECS;
      s_bDebugSMTP = GlobalDebug.isDebugMode ();
      s_aConnectionListeners.clear ();
      s_aEmailDataTransportListeners.clear ();
    });
  }
700476
function throttled (fn, delay) {
  let lastCall = 0
  return function (...args) {
    const now = new Date().getTime()
    if (now - lastCall < delay) {
      return
    }
    lastCall = now
    return fn(...args)
  }
}
642512
def wait(self):
        """"""
        now = _monotonic()
        if now < self._ref:
            delay = max(0, self._ref - now)
            self.sleep_func(delay)
        self._update_ref()
1115830
public void initTimer(){
		stopTimer();
		if(this.WRITE_CACHE_ENABLED) {
			logger.debug("configuring write cache with defaults");
			timerWriteCache = new TripleWriteCache(this);
			writeTimer = new Timer();
			writeTimer.scheduleAtFixedRate(timerWriteCache, TripleWriteCache.DEFAULT_INITIAL_DELAY, TripleWriteCache.DEFAULT_CACHE_MILLIS);
		}
		if(this.DELETE_CACHE_ENABLED) {
			logger.debug("configuring delete cache with defaults");
			timerDeleteCache = new TripleDeleteCache(this);
			deleteTimer = new Timer();
			deleteTimer.scheduleAtFixedRate(timerDeleteCache, TripleDeleteCache.DEFAULT_INITIAL_DELAY, TripleDeleteCache.DEFAULT_CACHE_MILLIS);
		}
	}
648146
public void setDefaultChainQuiesceTimeout(Object value) {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
            Tr.event(tc, "Setting default chain quiesce timeout [" + value + "]");
        }
        try {
            long num = MetatypeUtils.parseLong(PROPERTY_CONFIG_ALIAS, PROPERTY_CHAIN_QUIESCETIMEOUT, value, chainQuiesceTimeout);
            if (0 < num) {
                this.chainQuiesceTimeout = num;
            } else {
                if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
                    Tr.event(tc, "Timeout is too low");
                }
            }
        } catch (NumberFormatException nfe) {
            if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
                Tr.event(tc, "Timeout is not a number");
            }
        }
    }
358393
def on_pause(self):
        """"""
        self.engine.commit()
        self.strings.save()
        self.funcs.save()
        self.config.write()
1047563
def format_delay(self, delay, limit, bucket, environ, start_response):
        

        # Set up the default status
        status = self.conf.status

        # Set up the retry-after header...
        headers = HeadersDict([('Retry-After', "%d" % math.ceil(delay))])

        # Let format fiddle with the headers
        status, entity = limit.format(status, headers, environ, bucket,
                                      delay)

        # Return the response
        start_response(status, headers.items())
        return entity
1115881
def p_delays(self, p):
        ''
        p[0] = DelayStatement(p[3], lineno=p.lineno(1))
        p.set_lineno(0, p.lineno(1))
52445
public static Action delay(final Integer delay) {
        return new Action(input -> {
            try {
                Thread.sleep(delay);
            } catch (InterruptedException e) {
                Thread.currentThread().interrupt();
            }
            return input;
        });
    }
1068868
def delay(self):
        """"""
        if self.next_request_timestamp is None:
            return
        sleep_seconds = self.next_request_timestamp - time.time()
        if sleep_seconds <= 0:
            return
        message = "Sleeping: {:0.2f} seconds prior to" " call".format(
            sleep_seconds
        )
        log.debug(message)
        time.sleep(sleep_seconds)
631402
function throttle(func, delay) {
      var recent;
      return function throttled() {
        var context = this;
        var args = arguments;
        var now = $mdUtil.now();

        if (!recent || (now - recent > delay)) {
          func.apply(context, args);
          recent = now;
        }
      };
    }
648437
def fn(self, i, n=1, interval=0, pre_dl=None, post_dl=None):
        
        self.delay(pre_dl)
        self.k.tap_key(self.k.function_keys[i], n, interval)
        self.delay(post_dl)
730014
function debounce(fn, delay) {
        return function () {
          var self = this, args = arguments;
          clearTimeout(timer);
          console.log('debounce()');
          timer = setTimeout(function () {
            fn.apply(self, args);
          }, delay);
        };
      }