OLD | NEW |
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 CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ |
6 #define CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ | 6 #define CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 // deserialize previously persisted device settings. | 99 // deserialize previously persisted device settings. |
100 // Deserializes from signed setting on device as std::string into a | 100 // Deserializes from signed setting on device as std::string into a |
101 // protobuf and then into the config. | 101 // protobuf and then into the config. |
102 bool DeserializeForDevice(const std::string& input); | 102 bool DeserializeForDevice(const std::string& input); |
103 | 103 |
104 // Serializes config into a ProxyConfigDictionary and then std::string | 104 // Serializes config into a ProxyConfigDictionary and then std::string |
105 // persisted as string property in shill for a network. | 105 // persisted as string property in shill for a network. |
106 bool SerializeForNetwork(std::string* output); | 106 bool SerializeForNetwork(std::string* output); |
107 | 107 |
108 // Encodes the proxy server as "<url-scheme>=<proxy-scheme>://<proxy>" | 108 // Encodes the proxy server as "<url-scheme>=<proxy-scheme>://<proxy>" |
109 static void EncodeAndAppendProxyServer(const std::string& scheme, | 109 static void EncodeAndAppendProxyServer(const std::string& url_scheme, |
110 const net::ProxyServer& server, | 110 const net::ProxyServer& server, |
111 std::string* spec); | 111 std::string* spec); |
112 | 112 |
113 Mode mode; | 113 Mode mode; |
114 | 114 |
115 ProxyPrefs::ConfigState state; | 115 ProxyPrefs::ConfigState state; |
116 | 116 |
117 // True if user can modify proxy settings via UI. | 117 // True if user can modify proxy settings via UI. |
118 // If proxy is managed by policy or extension or other_precde or is for | 118 // If proxy is managed by policy or extension or other_precde or is for |
119 // shared network but kUseSharedProxies is turned off, it can't be modified | 119 // shared network but kUseSharedProxies is turned off, it can't be modified |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
295 std::vector<base::Closure> callbacks_; | 295 std::vector<base::Closure> callbacks_; |
296 | 296 |
297 base::WeakPtrFactory<ProxyConfigServiceImpl> pointer_factory_; | 297 base::WeakPtrFactory<ProxyConfigServiceImpl> pointer_factory_; |
298 | 298 |
299 DISALLOW_COPY_AND_ASSIGN(ProxyConfigServiceImpl); | 299 DISALLOW_COPY_AND_ASSIGN(ProxyConfigServiceImpl); |
300 }; | 300 }; |
301 | 301 |
302 } // namespace chromeos | 302 } // namespace chromeos |
303 | 303 |
304 #endif // CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ | 304 #endif // CHROME_BROWSER_CHROMEOS_PROXY_CONFIG_SERVICE_IMPL_H_ |
OLD | NEW |