1. Token CRCs are not handled correctly. This adds the corrected Whispernet binary...
[chromium-blink-merge.git] / chrome / browser / net / proxy_service_factory.h
blobb91c2e36e6fa8a8780b2b13041ceb4c02040fa96
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_NET_PROXY_SERVICE_FACTORY_H_
6 #define CHROME_BROWSER_NET_PROXY_SERVICE_FACTORY_H_
8 #include "base/basictypes.h"
10 class PrefProxyConfigTracker;
11 class PrefService;
13 namespace base {
14 class CommandLine;
17 namespace net {
18 class NetLog;
19 class NetworkDelegate;
20 class ProxyConfigService;
21 class ProxyService;
22 class URLRequestContext;
25 class ProxyServiceFactory {
26 public:
27 // Creates a ProxyConfigService that delivers the system preferences
28 // (or the respective ChromeOS equivalent).
29 static net::ProxyConfigService* CreateProxyConfigService(
30 PrefProxyConfigTracker* tracker);
32 // Creates a PrefProxyConfigTracker that tracks preferences of a
33 // profile. On ChromeOS it additionaly tracks local state for shared proxy
34 // settings. This tracker should be used if the profile's preferences should
35 // be respected. On ChromeOS's signin screen this is for example not the case.
36 static PrefProxyConfigTracker* CreatePrefProxyConfigTrackerOfProfile(
37 PrefService* profile_prefs,
38 PrefService* local_state_prefs);
40 // Creates a PrefProxyConfigTracker that tracks local state only. This tracker
41 // should be used for the system request context and the signin screen
42 // (ChromeOS only).
43 static PrefProxyConfigTracker* CreatePrefProxyConfigTrackerOfLocalState(
44 PrefService* local_state_prefs);
46 // Create a proxy service according to the options on command line.
47 static net::ProxyService* CreateProxyService(
48 net::NetLog* net_log,
49 net::URLRequestContext* context,
50 net::NetworkDelegate* network_delegate,
51 net::ProxyConfigService* proxy_config_service,
52 const base::CommandLine& command_line,
53 bool quick_check_enabled);
55 private:
56 DISALLOW_IMPLICIT_CONSTRUCTORS(ProxyServiceFactory);
59 #endif // CHROME_BROWSER_NET_PROXY_SERVICE_FACTORY_H_