Determines whether this record is expired or not.

        :param max_idle_seconds: (long), the maximum idle time of record, maximum time after the last access time.
        :return: (bool), ``true`` is this record is not expired.

def is_expired(self, max_idle_seconds):
        """
        Determines whether this record is expired or not.

        :param max_idle_seconds: (long), the maximum idle time of record, maximum time after the last access time.
        :return: (bool), ``true`` is this record is not expired.
        """

        now = current_time()
        return (self.expiration_time is not None and self.expiration_time < now) or \
               (max_idle_seconds is not None and self.last_access_time + max_idle_seconds < now)