Add a minor text member to ui::MenuModel.
[chromium-blink-merge.git] / chrome / browser / net / proxy_service_factory.h
blobf16e2267193fe573b5930a345cedbcad923d297d
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 CommandLine;
11 class PrefProxyConfigTracker;
12 class PrefService;
14 namespace net {
15 class NetLog;
16 class NetworkDelegate;
17 class ProxyConfigService;
18 class ProxyService;
19 class URLRequestContext;
22 class ProxyServiceFactory {
23 public:
24 // Creates a ProxyConfigService that delivers the system preferences
25 // (or the respective ChromeOS equivalent).
26 static net::ProxyConfigService* CreateProxyConfigService(
27 PrefProxyConfigTracker* tracker);
29 // Creates a PrefProxyConfigTracker that tracks preferences of a
30 // profile. On ChromeOS it additionaly tracks local state for shared proxy
31 // settings. This tracker should be used if the profile's preferences should
32 // be respected. On ChromeOS's signin screen this is for example not the case.
33 static PrefProxyConfigTracker* CreatePrefProxyConfigTrackerOfProfile(
34 PrefService* profile_prefs,
35 PrefService* local_state_prefs);
37 // Creates a PrefProxyConfigTracker that tracks local state only. This tracker
38 // should be used for the system request context and the signin screen
39 // (ChromeOS only).
40 static PrefProxyConfigTracker* CreatePrefProxyConfigTrackerOfLocalState(
41 PrefService* local_state_prefs);
43 // Create a proxy service according to the options on command line.
44 static net::ProxyService* CreateProxyService(
45 net::NetLog* net_log,
46 net::URLRequestContext* context,
47 net::NetworkDelegate* network_delegate,
48 net::ProxyConfigService* proxy_config_service,
49 const CommandLine& command_line);
51 private:
52 DISALLOW_IMPLICIT_CONSTRUCTORS(ProxyServiceFactory);
55 #endif // CHROME_BROWSER_NET_PROXY_SERVICE_FACTORY_H_