Chromium Code Reviews| 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 #include "net/dns/host_resolver.h" | 5 #include "net/dns/host_resolver.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/metrics/field_trial.h" | 8 #include "base/metrics/field_trial.h" |
| 9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
| 10 #include "base/strings/string_split.h" | 10 #include "base/strings/string_split.h" |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 83 limits.reserved_slots = parsed; | 83 limits.reserved_slots = parsed; |
| 84 return limits; | 84 return limits; |
| 85 } | 85 } |
| 86 | 86 |
| 87 HostResolver::Options::Options() | 87 HostResolver::Options::Options() |
| 88 : max_concurrent_resolves(kDefaultParallelism), | 88 : max_concurrent_resolves(kDefaultParallelism), |
| 89 max_retry_attempts(kDefaultRetryAttempts), | 89 max_retry_attempts(kDefaultRetryAttempts), |
| 90 enable_caching(true) { | 90 enable_caching(true) { |
| 91 } | 91 } |
| 92 | 92 |
| 93 HostResolver::RequestInfo::RequestInfo(const HostPortPair& host_port_pair) | 93 HostResolver::RequestInfo::RequestInfo(const HostPortPair& host_port_pair) |
|
Charlie Harrison
2016/07/26 13:41:13
Can this constructor call into the no argument con
Julia Tuttle
2016/07/26 17:51:24
Done.
| |
| 94 : host_port_pair_(host_port_pair), | 94 : host_port_pair_(host_port_pair), |
| 95 address_family_(ADDRESS_FAMILY_UNSPECIFIED), | 95 address_family_(ADDRESS_FAMILY_UNSPECIFIED), |
| 96 host_resolver_flags_(0), | 96 host_resolver_flags_(0), |
| 97 allow_cached_response_(true), | 97 allow_cached_response_(true), |
| 98 is_speculative_(false), | 98 is_speculative_(false), |
| 99 is_my_ip_address_(false) {} | 99 is_my_ip_address_(false) {} |
| 100 | 100 |
| 101 HostResolver::RequestInfo::RequestInfo(const RequestInfo& request_info) | |
| 102 : host_port_pair_(request_info.host_port_pair_), | |
| 103 address_family_(request_info.address_family_), | |
| 104 host_resolver_flags_(request_info.host_resolver_flags_), | |
| 105 allow_cached_response_(request_info.allow_cached_response_), | |
| 106 is_speculative_(request_info.is_speculative_), | |
| 107 is_my_ip_address_(request_info.is_my_ip_address_), | |
| 108 cache_hit_callback_(request_info.cache_hit_callback_) {} | |
| 109 | |
| 110 HostResolver::RequestInfo::~RequestInfo() {} | |
| 111 | |
| 112 HostResolver::RequestInfo::RequestInfo() | |
| 113 : address_family_(ADDRESS_FAMILY_UNSPECIFIED), | |
| 114 host_resolver_flags_(0), | |
| 115 allow_cached_response_(true), | |
| 116 is_speculative_(false), | |
| 117 is_my_ip_address_(false) {} | |
| 118 | |
| 101 HostResolver::~HostResolver() { | 119 HostResolver::~HostResolver() { |
| 102 } | 120 } |
| 103 | 121 |
| 104 void HostResolver::SetDnsClientEnabled(bool enabled) { | 122 void HostResolver::SetDnsClientEnabled(bool enabled) { |
| 105 } | 123 } |
| 106 | 124 |
| 107 void HostResolver::ChangeRequestPriority(RequestHandle req, | 125 void HostResolver::ChangeRequestPriority(RequestHandle req, |
| 108 RequestPriority priority) { | 126 RequestPriority priority) { |
| 109 NOTIMPLEMENTED(); | 127 NOTIMPLEMENTED(); |
| 110 } | 128 } |
| (...skipping 17 matching lines...) Expand all Loading... | |
| 128 std::unique_ptr<HostResolver> HostResolver::CreateDefaultResolver( | 146 std::unique_ptr<HostResolver> HostResolver::CreateDefaultResolver( |
| 129 NetLog* net_log) { | 147 NetLog* net_log) { |
| 130 return std::unique_ptr<HostResolver>( | 148 return std::unique_ptr<HostResolver>( |
| 131 new HostResolverImpl(Options(), net_log)); | 149 new HostResolverImpl(Options(), net_log)); |
| 132 } | 150 } |
| 133 | 151 |
| 134 HostResolver::HostResolver() { | 152 HostResolver::HostResolver() { |
| 135 } | 153 } |
| 136 | 154 |
| 137 } // namespace net | 155 } // namespace net |
| OLD | NEW |