Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(168)

Side by Side Diff: net/proxy/proxy_info.h

Issue 266243004: Clang format slam. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef NET_PROXY_PROXY_INFO_H_ 5 #ifndef NET_PROXY_PROXY_INFO_H_
6 #define NET_PROXY_PROXY_INFO_H_ 6 #define NET_PROXY_PROXY_INFO_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 } 83 }
84 84
85 // Returns true if the first valid proxy server is a socks server. 85 // Returns true if the first valid proxy server is a socks server.
86 bool is_socks() const { 86 bool is_socks() const {
87 if (is_empty()) 87 if (is_empty())
88 return false; 88 return false;
89 return proxy_server().is_socks(); 89 return proxy_server().is_socks();
90 } 90 }
91 91
92 // Returns true if this proxy info has no proxies left to try. 92 // Returns true if this proxy info has no proxies left to try.
93 bool is_empty() const { 93 bool is_empty() const { return proxy_list_.IsEmpty(); }
94 return proxy_list_.IsEmpty();
95 }
96 94
97 // Returns true if this proxy resolution is using a direct connection due to 95 // Returns true if this proxy resolution is using a direct connection due to
98 // proxy bypass rules. 96 // proxy bypass rules.
99 bool did_bypass_proxy() const { 97 bool did_bypass_proxy() const { return did_bypass_proxy_; }
100 return did_bypass_proxy_;
101 }
102 98
103 // Returns true if the proxy resolution was done using a PAC script. 99 // Returns true if the proxy resolution was done using a PAC script.
104 bool did_use_pac_script() const { 100 bool did_use_pac_script() const { return did_use_pac_script_; }
105 return did_use_pac_script_;
106 }
107 101
108 // Returns the first valid proxy server. is_empty() must be false to be able 102 // Returns the first valid proxy server. is_empty() must be false to be able
109 // to call this function. 103 // to call this function.
110 const ProxyServer& proxy_server() const { return proxy_list_.Get(); } 104 const ProxyServer& proxy_server() const { return proxy_list_.Get(); }
111 105
112 // Returns the source for configuration settings used for proxy resolution. 106 // Returns the source for configuration settings used for proxy resolution.
113 ProxyConfigSource config_source() const { return config_source_; } 107 ProxyConfigSource config_source() const { return config_source_; }
114 108
115 // See description in ProxyList::ToPacString(). 109 // See description in ProxyList::ToPacString().
116 std::string ToPacString() const; 110 std::string ToPacString() const;
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 161
168 // How long it took to resolve the proxy. Times are both null if proxy was 162 // How long it took to resolve the proxy. Times are both null if proxy was
169 // determined synchronously without running a PAC. 163 // determined synchronously without running a PAC.
170 base::TimeTicks proxy_resolve_start_time_; 164 base::TimeTicks proxy_resolve_start_time_;
171 base::TimeTicks proxy_resolve_end_time_; 165 base::TimeTicks proxy_resolve_end_time_;
172 }; 166 };
173 167
174 } // namespace net 168 } // namespace net
175 169
176 #endif // NET_PROXY_PROXY_INFO_H_ 170 #endif // NET_PROXY_PROXY_INFO_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698