#include "extensions/renderer/extension_throttle_entry.h"
#include <algorithm>
#include <cmath>
#include <memory>
#include <utility>
#include "base/check_op.h"
#include "base/rand_util.h"
#include "base/strings/string_number_conversions.h"
#include "base/values.h"
namespace extensions {
const int ExtensionThrottleEntry::kDefaultSlidingWindowPeriodMs = …;
const int ExtensionThrottleEntry::kDefaultMaxSendThreshold = …;
const int ExtensionThrottleEntry::kDefaultNumErrorsToIgnore = …;
const int ExtensionThrottleEntry::kDefaultInitialDelayMs = …;
const double ExtensionThrottleEntry::kDefaultMultiplyFactor = …;
const double ExtensionThrottleEntry::kDefaultJitterFactor = …;
const int ExtensionThrottleEntry::kDefaultMaximumBackoffMs = …;
const int ExtensionThrottleEntry::kDefaultEntryLifetimeMs = …;
ExtensionThrottleEntry::ExtensionThrottleEntry(const std::string& url_id)
: … { … }
ExtensionThrottleEntry::ExtensionThrottleEntry(
const std::string& url_id,
const net::BackoffEntry::Policy* backoff_policy)
: … { … }
bool ExtensionThrottleEntry::IsEntryOutdated() const { … }
void ExtensionThrottleEntry::DisableBackoffThrottling() { … }
bool ExtensionThrottleEntry::ShouldRejectRequest() const { … }
int64_t ExtensionThrottleEntry::ReserveSendingTimeForNextRequest(
const base::TimeTicks& earliest_time) { … }
base::TimeTicks ExtensionThrottleEntry::GetExponentialBackoffReleaseTime()
const { … }
void ExtensionThrottleEntry::UpdateWithResponse(int status_code) { … }
void ExtensionThrottleEntry::ReceivedContentWasMalformed(int response_code) { … }
const std::string& ExtensionThrottleEntry::GetURLIdForDebugging() const { … }
ExtensionThrottleEntry::~ExtensionThrottleEntry() = default;
void ExtensionThrottleEntry::Initialize() { … }
bool ExtensionThrottleEntry::IsConsideredSuccess(int response_code) { … }
base::TimeTicks ExtensionThrottleEntry::ImplGetTimeNow() const { … }
const net::BackoffEntry* ExtensionThrottleEntry::GetBackoffEntry() const { … }
net::BackoffEntry* ExtensionThrottleEntry::GetBackoffEntry() { … }
}