Check if a given RiakObject has expired.
974786
private function isExpired(RiakObject $object) : bool
    {
        $metadataMap = $object->getMetadataMap();

        return isset($metadataMap[self::EXPIRES_HEADER])
            && $metadataMap[self::EXPIRES_HEADER] < time();
    }
509396
def expired(self):
        """"""
        now = timezone.now()
        if self.created < now - token_settings.EXPIRING_TOKEN_LIFESPAN:
            return True
        return False
426001
public boolean expired(int expiration) {
        if (null == cliContext) {
            return true;
        }
        if ((daemon || cliContext.inProgress()) && !cliContext.disconnected()) {
            return false;
        }
        long l = expiration * 1000;
        return l < ($.ms() - ts);
    }
344382
public boolean isExpired()
    {
        if (tc.isEntryEnabled())
            Tr.entry(tc, "isExpired");
        boolean expired = false;
        long curTime = System.currentTimeMillis();
        //TODO:
        if (curTime - _leaseTime > _leaseTimeout * 1000) //  30 seconds default for timeout
        {
            if (tc.isDebugEnabled())
                Tr.debug(tc, "Lease has EXPIRED for " + _recoveryIdentity + ", currenttime: " + curTime + ", storedTime: " + _leaseTime);
            expired = true;
        }
        else
        {
            if (tc.isDebugEnabled())
                Tr.debug(tc, "Lease has not expired for " + _recoveryIdentity + ", currenttime: " + curTime + ", storedTime: " + _leaseTime);
        }

        if (tc.isEntryEnabled())
            Tr.exit(tc, "isExpired", expired);
        return expired;
    }
1153494
def expired?(request, method)
      if (expires_at = request.expires_at) && expires_at > 0 && (now = Time.now.to_i) >= expires_at
        @reject_stats.update("expired (#{method})")
        Log.info("REJECT EXPIRED <#{request.token}> from #{request.from} TTL #{RightSupport::Stats.elapsed(now - expires_at)} ago")
        # For agents that do not know about non-delivery, use error result
        if can_handle_non_delivery_result?(request.recv_version)
          OperationResult.non_delivery(OperationResult::TTL_EXPIRATION)
        else
          OperationResult.error("Could not deliver request (#{OperationResult::TTL_EXPIRATION})")
        end
      end
    end
455063
@SuppressWarnings("ShortCircuitBoolean")
  boolean hasExpired(Node<K, V> node, long now) {
    return (expiresAfterAccess() && (now - node.getAccessTime() >= expiresAfterAccessNanos()))
        | (expiresAfterWrite() && (now - node.getWriteTime() >= expiresAfterWriteNanos()))
        | (expiresVariable() && (now - node.getVariableTime() >= 0));
  }
160928
def check_precondition(self, key, value):
        '''
        
        '''
        timeout = float(value)
        curr_time = self.get_current_time()
        if curr_time > timeout:
            return True
        return False
946497
def hasExpired(self):
        
        return (datetime.datetime.utcnow() - self.lastUpdateTime).total_seconds() > self.maxAgeSeconds
875819
public function isExpired()
    {
        if (is_object($this->ExpireAtDate)) {
            $this->ExpireAtDate = $this->ExpireAtDate->Value;
        }

        $expired = false;

        if (!empty($this->ExpireAtDate)) {
            if (SS_Datetime::now()->Value >= $this->ExpireAtDate) {
                $expired = true;
            }
        }

        return $expired;
    }
125529
def _parse_expiry(response_data):
    
    expires_in = response_data.get('expires_in', None)

    if expires_in is not None:
        return _helpers.utcnow() + datetime.timedelta(
            seconds=expires_in)
    else:
        return None
1115790
def expired(self):
        """"""
        self._data["_killed"] = True
        self.save()
        raise SessionExpired(self._config.expired_message)
795811
protected boolean checkForExpiration(CacheItem item) throws Exception {
        if (item.isExpired(ticks.get())) {
            cacheStoreAdapter.remove(item.getScope(), item.getKey());

            return true;
        } else {
            return false;
        }
    }
1024228
protected boolean isExpiredAt(long time) {
        try (Lock ignored = locker.lockIfNotHeld()) {
            checkValidForRead();
            return sessionData.isExpiredAt(time);
        }
    }
1081490
def expired(self):
        
        if self._expired_latch:
            return True

        self._check_time_backwards()

        if time.time() > self.end:
            self._expired_latch = True
            return True

        return False
1173073
public void clearExpired() {
		Iterator keys = cacheLineTable.keySet().iterator();

		while (keys.hasNext()) {
			Object key = keys.next();

			if (hasExpired(key)) {
				removeObject(key);
			}
		}
	}
484145
def CheckBreakpointsExpiration(self):
    """"""
    with self._lock:
      current_time = BreakpointsManager.GetCurrentTime()
      if self._next_expiration > current_time:
        return

      expired_breakpoints = []
      self._next_expiration = datetime.max
      for breakpoint in six.itervalues(self._active):
        expiration_time = breakpoint.GetExpirationTime()
        if expiration_time <= current_time:
          expired_breakpoints.append(breakpoint)
        else:
          self._next_expiration = min(self._next_expiration, expiration_time)

    for breakpoint in expired_breakpoints:
      breakpoint.ExpireBreakpoint()
1308028
def expires_at(self):
        """"""
        try:
            expires = min(sig.key_expiration for sig in itertools.chain(iter(uid.selfsig for uid in self.userids), self.self_signatures)
                          if sig.key_expiration is not None)

        except ValueError:
            return None

        else:
            return (self.created + expires)