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

Side by Side Diff: net/base/host_resolver_impl.h

Issue 10831277: [net] Change factory methods for HostResolver and HostCache to return a scoped_ptr (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add ChromeBrowserFieldTrials::AsyncDnsFieldTrial Created 8 years, 4 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_BASE_HOST_RESOLVER_IMPL_H_ 5 #ifndef NET_BASE_HOST_RESOLVER_IMPL_H_
6 #define NET_BASE_HOST_RESOLVER_IMPL_H_ 6 #define NET_BASE_HOST_RESOLVER_IMPL_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 // run at once. This upper-bounds the total number of outstanding 110 // run at once. This upper-bounds the total number of outstanding
111 // DNS transactions (not counting retransmissions and retries). 111 // DNS transactions (not counting retransmissions and retries).
112 // 112 //
113 // |dns_config_service| will be used to detect changes to DNS configuration 113 // |dns_config_service| will be used to detect changes to DNS configuration
114 // and obtain DnsConfig for DnsClient. 114 // and obtain DnsConfig for DnsClient.
115 // 115 //
116 // |dns_client|, if set, will be used to resolve requests. 116 // |dns_client|, if set, will be used to resolve requests.
117 // 117 //
118 // |net_log| must remain valid for the life of the HostResolverImpl. 118 // |net_log| must remain valid for the life of the HostResolverImpl.
119 // TODO(szym): change to scoped_ptr<HostCache>. 119 // TODO(szym): change to scoped_ptr<HostCache>.
120 HostResolverImpl(HostCache* cache, 120 HostResolverImpl(scoped_ptr<HostCache> cache,
121 const PrioritizedDispatcher::Limits& job_limits, 121 const PrioritizedDispatcher::Limits& job_limits,
122 const ProcTaskParams& proc_params, 122 const ProcTaskParams& proc_params,
123 scoped_ptr<DnsConfigService> dns_config_service, 123 scoped_ptr<DnsConfigService> dns_config_service,
124 scoped_ptr<DnsClient> dns_client, 124 scoped_ptr<DnsClient> dns_client,
125 NetLog* net_log); 125 NetLog* net_log);
126 126
127 // If any completion callbacks are pending when the resolver is destroyed, 127 // If any completion callbacks are pending when the resolver is destroyed,
128 // the host resolutions are cancelled, and the completion callbacks will not 128 // the host resolutions are cancelled, and the completion callbacks will not
129 // be called. 129 // be called.
130 virtual ~HostResolverImpl(); 130 virtual ~HostResolverImpl();
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 HostResolverFlags additional_resolver_flags_; 270 HostResolverFlags additional_resolver_flags_;
271 271
272 NetLog* net_log_; 272 NetLog* net_log_;
273 273
274 DISALLOW_COPY_AND_ASSIGN(HostResolverImpl); 274 DISALLOW_COPY_AND_ASSIGN(HostResolverImpl);
275 }; 275 };
276 276
277 } // namespace net 277 } // namespace net
278 278
279 #endif // NET_BASE_HOST_RESOLVER_IMPL_H_ 279 #endif // NET_BASE_HOST_RESOLVER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698