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

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

Issue 1356933002: make ProxyService::CreateSystemProxyConfigService return scoped_ptrs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: small ios fix Created 5 years, 3 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_SERVICE_MOJO_H_ 5 #ifndef NET_PROXY_PROXY_SERVICE_MOJO_H_
6 #define NET_PROXY_PROXY_SERVICE_MOJO_H_ 6 #define NET_PROXY_PROXY_SERVICE_MOJO_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "net/proxy/dhcp_proxy_script_fetcher.h" 10 #include "net/proxy/dhcp_proxy_script_fetcher.h"
11 11
12 namespace net { 12 namespace net {
13 namespace interfaces { 13 namespace interfaces {
14 class ProxyResolverFactory; 14 class ProxyResolverFactory;
15 } 15 }
16 16
17 class HostResolver; 17 class HostResolver;
18 class MojoProxyResolverFactory; 18 class MojoProxyResolverFactory;
19 class NetLog; 19 class NetLog;
20 class NetworkDelegate; 20 class NetworkDelegate;
21 class ProxyConfigService; 21 class ProxyConfigService;
22 class ProxyScriptFetcher; 22 class ProxyScriptFetcher;
23 class ProxyService; 23 class ProxyService;
24 24
25 // Creates a proxy service that uses |mojo_proxy_factory| to create and connect 25 // Creates a proxy service that uses |mojo_proxy_factory| to create and connect
26 // to a Mojo proxy resolver service. This proxy service polls 26 // to a Mojo proxy resolver service. This proxy service polls
27 // |proxy_config_service| to notice when the proxy settings change. We take 27 // |proxy_config_service| to notice when the proxy settings change. We take
28 // ownership of |proxy_config_service|. 28 // ownership of |proxy_config_service|.
mmenke 2015/09/18 18:58:54 No need for last sentence anymore
Charlie Harrison 2015/09/18 19:56:06 Done.
29 // 29 //
30 // |proxy_script_fetcher| specifies the dependency to use for downloading 30 // |proxy_script_fetcher| specifies the dependency to use for downloading
31 // any PAC scripts. The resulting ProxyService will take ownership of it. 31 // any PAC scripts. The resulting ProxyService will take ownership of it.
32 // 32 //
33 // |dhcp_proxy_script_fetcher| specifies the dependency to use for attempting 33 // |dhcp_proxy_script_fetcher| specifies the dependency to use for attempting
34 // to retrieve the most appropriate PAC script configured in DHCP. 34 // to retrieve the most appropriate PAC script configured in DHCP.
35 // 35 //
36 // |host_resolver| points to the host resolving dependency the PAC script 36 // |host_resolver| points to the host resolving dependency the PAC script
37 // should use for any DNS queries. It must remain valid throughout the 37 // should use for any DNS queries. It must remain valid throughout the
38 // lifetime of the ProxyService. 38 // lifetime of the ProxyService.
39 scoped_ptr<ProxyService> CreateProxyServiceUsingMojoFactory( 39 scoped_ptr<ProxyService> CreateProxyServiceUsingMojoFactory(
40 MojoProxyResolverFactory* mojo_proxy_factory, 40 MojoProxyResolverFactory* mojo_proxy_factory,
41 ProxyConfigService* proxy_config_service, 41 scoped_ptr<ProxyConfigService> proxy_config_service,
42 ProxyScriptFetcher* proxy_script_fetcher, 42 ProxyScriptFetcher* proxy_script_fetcher,
43 scoped_ptr<DhcpProxyScriptFetcher> dhcp_proxy_script_fetcher, 43 scoped_ptr<DhcpProxyScriptFetcher> dhcp_proxy_script_fetcher,
44 HostResolver* host_resolver, 44 HostResolver* host_resolver,
45 NetLog* net_log, 45 NetLog* net_log,
46 NetworkDelegate* network_delegate); 46 NetworkDelegate* network_delegate);
47 47
48 // Creates a proxy service that connects to an in-process Mojo proxy resolver 48 // Creates a proxy service that connects to an in-process Mojo proxy resolver
49 // service. See above for information about other arguments. 49 // service. See above for information about other arguments.
50 // 50 //
51 // ########################################################################## 51 // ##########################################################################
52 // # See the warnings in net/proxy/proxy_resolver_v8.h describing the 52 // # See the warnings in net/proxy/proxy_resolver_v8.h describing the
53 // # multi-threading model. In order for this to be safe to use, *ALL* the 53 // # multi-threading model. In order for this to be safe to use, *ALL* the
54 // # other V8's running in the process must use v8::Locker. 54 // # other V8's running in the process must use v8::Locker.
55 // ########################################################################## 55 // ##########################################################################
56 scoped_ptr<ProxyService> CreateProxyServiceUsingMojoInProcess( 56 scoped_ptr<ProxyService> CreateProxyServiceUsingMojoInProcess(
57 ProxyConfigService* proxy_config_service, 57 scoped_ptr<ProxyConfigService> proxy_config_service,
58 ProxyScriptFetcher* proxy_script_fetcher, 58 ProxyScriptFetcher* proxy_script_fetcher,
59 scoped_ptr<DhcpProxyScriptFetcher> dhcp_proxy_script_fetcher, 59 scoped_ptr<DhcpProxyScriptFetcher> dhcp_proxy_script_fetcher,
60 HostResolver* host_resolver, 60 HostResolver* host_resolver,
61 NetLog* net_log, 61 NetLog* net_log,
62 NetworkDelegate* network_delegate); 62 NetworkDelegate* network_delegate);
63 63
64 } // namespace net 64 } // namespace net
65 65
66 #endif // NET_PROXY_PROXY_SERVICE_MOJO_H_ 66 #endif // NET_PROXY_PROXY_SERVICE_MOJO_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698