summaryrefslogtreecommitdiffstats
path: root/net/proxy
diff options
context:
space:
mode:
authorerg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-20 00:12:13 +0000
committererg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-01-20 00:12:13 +0000
commitbe1a48bcd64ea75939f38a9ab264ee99214313bb (patch)
treec9aa66838177a6e10757ae4547e731a490420bfa /net/proxy
parentf1e99b1b03848eb939fd3f51b56de1b23dfab057 (diff)
downloadchromium_src-be1a48bcd64ea75939f38a9ab264ee99214313bb.zip
chromium_src-be1a48bcd64ea75939f38a9ab264ee99214313bb.tar.gz
chromium_src-be1a48bcd64ea75939f38a9ab264ee99214313bb.tar.bz2
Even more reordering the methods in headers and implementation in net/.
BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6314010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@71880 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/proxy')
-rw-r--r--net/proxy/init_proxy_resolver.h18
-rw-r--r--net/proxy/polling_proxy_config_service.cc20
-rw-r--r--net/proxy/proxy_config.cc22
3 files changed, 30 insertions, 30 deletions
diff --git a/net/proxy/init_proxy_resolver.h b/net/proxy/init_proxy_resolver.h
index 2691be5..ec6bfc1 100644
--- a/net/proxy/init_proxy_resolver.h
+++ b/net/proxy/init_proxy_resolver.h
@@ -63,6 +63,15 @@ class InitProxyResolver {
CompletionCallback* callback);
private:
+ struct PacURL {
+ PacURL(bool auto_detect, const GURL& url)
+ : auto_detect(auto_detect), url(url) {}
+ bool auto_detect;
+ GURL url;
+ };
+
+ typedef std::vector<PacURL> UrlList;
+
enum State {
STATE_NONE,
STATE_WAIT,
@@ -73,15 +82,6 @@ class InitProxyResolver {
STATE_SET_PAC_SCRIPT_COMPLETE,
};
- struct PacURL {
- PacURL(bool auto_detect, const GURL& url)
- : auto_detect(auto_detect), url(url) {}
- bool auto_detect;
- GURL url;
- };
-
- typedef std::vector<PacURL> UrlList;
-
// Returns ordered list of PAC urls to try for |config|.
UrlList BuildPacUrlsFallbackList(const ProxyConfig& config) const;
diff --git a/net/proxy/polling_proxy_config_service.cc b/net/proxy/polling_proxy_config_service.cc
index 98a164d..01acac2 100644
--- a/net/proxy/polling_proxy_config_service.cc
+++ b/net/proxy/polling_proxy_config_service.cc
@@ -154,16 +154,6 @@ class PollingProxyConfigService::Core
bool poll_task_queued_;
};
-PollingProxyConfigService::PollingProxyConfigService(
- base::TimeDelta poll_interval,
- GetConfigFunction get_config_func)
- : core_(new Core(poll_interval, get_config_func)) {
-}
-
-PollingProxyConfigService::~PollingProxyConfigService() {
- core_->Orphan();
-}
-
void PollingProxyConfigService::AddObserver(Observer* observer) {
core_->AddObserver(observer);
}
@@ -180,6 +170,16 @@ void PollingProxyConfigService::OnLazyPoll() {
core_->OnLazyPoll();
}
+PollingProxyConfigService::PollingProxyConfigService(
+ base::TimeDelta poll_interval,
+ GetConfigFunction get_config_func)
+ : core_(new Core(poll_interval, get_config_func)) {
+}
+
+PollingProxyConfigService::~PollingProxyConfigService() {
+ core_->Orphan();
+}
+
void PollingProxyConfigService::CheckForChangesNow() {
core_->CheckForChangesNow();
}
diff --git a/net/proxy/proxy_config.cc b/net/proxy/proxy_config.cc
index ce14358..70e6549 100644
--- a/net/proxy/proxy_config.cc
+++ b/net/proxy/proxy_config.cc
@@ -32,17 +32,6 @@ ProxyConfig::ProxyRules::ProxyRules()
ProxyConfig::ProxyRules::~ProxyRules() {
}
-bool ProxyConfig::ProxyRules::Equals(const ProxyRules& other) const {
- return type == other.type &&
- single_proxy == other.single_proxy &&
- proxy_for_http == other.proxy_for_http &&
- proxy_for_https == other.proxy_for_https &&
- proxy_for_ftp == other.proxy_for_ftp &&
- fallback_proxy == other.fallback_proxy &&
- bypass_rules.Equals(other.bypass_rules) &&
- reverse_bypass == other.reverse_bypass;
-}
-
void ProxyConfig::ProxyRules::Apply(const GURL& url, ProxyInfo* result) {
if (empty()) {
result->UseDirect();
@@ -146,6 +135,17 @@ const ProxyServer* ProxyConfig::ProxyRules::MapUrlSchemeToProxy(
return NULL; // No mapping for this scheme. Use direct.
}
+bool ProxyConfig::ProxyRules::Equals(const ProxyRules& other) const {
+ return type == other.type &&
+ single_proxy == other.single_proxy &&
+ proxy_for_http == other.proxy_for_http &&
+ proxy_for_https == other.proxy_for_https &&
+ proxy_for_ftp == other.proxy_for_ftp &&
+ fallback_proxy == other.fallback_proxy &&
+ bypass_rules.Equals(other.bypass_rules) &&
+ reverse_bypass == other.reverse_bypass;
+}
+
ProxyServer* ProxyConfig::ProxyRules::MapUrlSchemeToProxyNoFallback(
const std::string& scheme) {
DCHECK_EQ(TYPE_PROXY_PER_SCHEME, type);