| 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 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 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 200 Key GetEffectiveKeyForRequest(const RequestInfo& info) const; | 200 Key GetEffectiveKeyForRequest(const RequestInfo& info) const; |
| 201 | 201 |
| 202 // Records the result in cache if cache is present. | 202 // Records the result in cache if cache is present. |
| 203 void CacheResult(const Key& key, | 203 void CacheResult(const Key& key, |
| 204 const HostCache::Entry& entry, | 204 const HostCache::Entry& entry, |
| 205 base::TimeDelta ttl); | 205 base::TimeDelta ttl); |
| 206 | 206 |
| 207 // Removes |job| from |jobs_|, only if it exists. | 207 // Removes |job| from |jobs_|, only if it exists. |
| 208 void RemoveJob(Job* job); | 208 void RemoveJob(Job* job); |
| 209 | 209 |
| 210 // Aborts all in progress jobs and notifies their requests. | 210 // Aborts all in progress jobs with the given |error| and notifies their |
| 211 // Might start new jobs. | 211 // requests. Might start new jobs. |
| 212 void AbortAllInProgressJobs(); | 212 void AbortAllInProgressJobs(int error); |
| 213 | 213 |
| 214 // Attempts to serve each Job in |jobs_| from the HOSTS file if we have | 214 // Attempts to serve each Job in |jobs_| from the HOSTS file if we have |
| 215 // a DnsClient with a valid DnsConfig. | 215 // a DnsClient with a valid DnsConfig. |
| 216 void TryServingAllJobsFromHosts(); | 216 void TryServingAllJobsFromHosts(); |
| 217 | 217 |
| 218 // NetworkChangeNotifier::IPAddressObserver: | 218 // NetworkChangeNotifier::IPAddressObserver: |
| 219 virtual void OnIPAddressChanged() OVERRIDE; | 219 virtual void OnIPAddressChanged() OVERRIDE; |
| 220 | 220 |
| 221 // NetworkChangeNotifier::DNSObserver: | 221 // NetworkChangeNotifier::DNSObserver: |
| 222 virtual void OnDNSChanged() OVERRIDE; | 222 virtual void OnDNSChanged() OVERRIDE; |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 275 HostResolverFlags additional_resolver_flags_; | 275 HostResolverFlags additional_resolver_flags_; |
| 276 | 276 |
| 277 NetLog* net_log_; | 277 NetLog* net_log_; |
| 278 | 278 |
| 279 DISALLOW_COPY_AND_ASSIGN(HostResolverImpl); | 279 DISALLOW_COPY_AND_ASSIGN(HostResolverImpl); |
| 280 }; | 280 }; |
| 281 | 281 |
| 282 } // namespace net | 282 } // namespace net |
| 283 | 283 |
| 284 #endif // NET_BASE_HOST_RESOLVER_IMPL_H_ | 284 #endif // NET_BASE_HOST_RESOLVER_IMPL_H_ |
| OLD | NEW |