| 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_DNS_HOST_RESOLVER_IMPL_H_ | 5 #ifndef NET_DNS_HOST_RESOLVER_IMPL_H_ |
| 6 #define NET_DNS_HOST_RESOLVER_IMPL_H_ | 6 #define NET_DNS_HOST_RESOLVER_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 // HostResolver methods: | 133 // HostResolver methods: |
| 134 int Resolve(const RequestInfo& info, | 134 int Resolve(const RequestInfo& info, |
| 135 RequestPriority priority, | 135 RequestPriority priority, |
| 136 AddressList* addresses, | 136 AddressList* addresses, |
| 137 const CompletionCallback& callback, | 137 const CompletionCallback& callback, |
| 138 RequestHandle* out_req, | 138 RequestHandle* out_req, |
| 139 const BoundNetLog& source_net_log) override; | 139 const BoundNetLog& source_net_log) override; |
| 140 int ResolveFromCache(const RequestInfo& info, | 140 int ResolveFromCache(const RequestInfo& info, |
| 141 AddressList* addresses, | 141 AddressList* addresses, |
| 142 const BoundNetLog& source_net_log) override; | 142 const BoundNetLog& source_net_log) override; |
| 143 void ChangeRequestPriority(RequestHandle req, |
| 144 RequestPriority priority) override; |
| 143 void CancelRequest(RequestHandle req) override; | 145 void CancelRequest(RequestHandle req) override; |
| 144 void SetDnsClientEnabled(bool enabled) override; | 146 void SetDnsClientEnabled(bool enabled) override; |
| 145 HostCache* GetHostCache() override; | 147 HostCache* GetHostCache() override; |
| 146 std::unique_ptr<base::Value> GetDnsConfigAsValue() const override; | 148 std::unique_ptr<base::Value> GetDnsConfigAsValue() const override; |
| 147 | 149 |
| 148 void set_proc_params_for_test(const ProcTaskParams& proc_params) { | 150 void set_proc_params_for_test(const ProcTaskParams& proc_params) { |
| 149 proc_params_ = proc_params; | 151 proc_params_ = proc_params; |
| 150 } | 152 } |
| 151 | 153 |
| 152 private: | 154 private: |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 324 // This function is only exposed so it can be unit-tested. | 326 // This function is only exposed so it can be unit-tested. |
| 325 // TODO(tfarina): It would be better to change the tests so this function | 327 // TODO(tfarina): It would be better to change the tests so this function |
| 326 // gets exercised indirectly through HostResolverImpl. | 328 // gets exercised indirectly through HostResolverImpl. |
| 327 NET_EXPORT_PRIVATE bool ResolveLocalHostname(base::StringPiece host, | 329 NET_EXPORT_PRIVATE bool ResolveLocalHostname(base::StringPiece host, |
| 328 uint16_t port, | 330 uint16_t port, |
| 329 AddressList* address_list); | 331 AddressList* address_list); |
| 330 | 332 |
| 331 } // namespace net | 333 } // namespace net |
| 332 | 334 |
| 333 #endif // NET_DNS_HOST_RESOLVER_IMPL_H_ | 335 #endif // NET_DNS_HOST_RESOLVER_IMPL_H_ |
| OLD | NEW |