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/proxy/multi_threaded_proxy_resolver.h" | 5 #include "net/proxy/multi_threaded_proxy_resolver.h" |
6 | 6 |
7 #include <deque> | 7 #include <deque> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/bind_helpers.h" | 12 #include "base/bind_helpers.h" |
13 #include "base/location.h" | 13 #include "base/location.h" |
14 #include "base/single_thread_task_runner.h" | 14 #include "base/single_thread_task_runner.h" |
15 #include "base/stl_util.h" | 15 #include "base/stl_util.h" |
16 #include "base/strings/string_util.h" | 16 #include "base/strings/string_util.h" |
17 #include "base/strings/stringprintf.h" | 17 #include "base/strings/stringprintf.h" |
18 #include "base/threading/non_thread_safe.h" | 18 #include "base/threading/non_thread_safe.h" |
19 #include "base/threading/thread.h" | 19 #include "base/threading/thread.h" |
20 #include "base/threading/thread_restrictions.h" | 20 #include "base/threading/thread_restrictions.h" |
21 #include "base/threading/thread_task_runner_handle.h" | 21 #include "base/threading/thread_task_runner_handle.h" |
22 #include "net/base/net_errors.h" | 22 #include "net/base/net_errors.h" |
23 #include "net/log/net_log.h" | 23 #include "net/log/net_log.h" |
24 #include "net/log/net_log_event_type.h" | 24 #include "net/log/net_log_event_type.h" |
| 25 #include "net/log/net_log_with_source.h" |
25 #include "net/proxy/proxy_info.h" | 26 #include "net/proxy/proxy_info.h" |
26 #include "net/proxy/proxy_resolver.h" | 27 #include "net/proxy/proxy_resolver.h" |
27 | 28 |
28 namespace net { | 29 namespace net { |
29 namespace { | 30 namespace { |
30 class Job; | 31 class Job; |
31 | 32 |
32 // An "executor" is a job-runner for PAC requests. It encapsulates a worker | 33 // An "executor" is a job-runner for PAC requests. It encapsulates a worker |
33 // thread and a synchronous ProxyResolver (which will be operated on said | 34 // thread and a synchronous ProxyResolver (which will be operated on said |
34 // thread.) | 35 // thread.) |
(...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
628 return ERR_IO_PENDING; | 629 return ERR_IO_PENDING; |
629 } | 630 } |
630 | 631 |
631 void MultiThreadedProxyResolverFactory::RemoveJob( | 632 void MultiThreadedProxyResolverFactory::RemoveJob( |
632 MultiThreadedProxyResolverFactory::Job* job) { | 633 MultiThreadedProxyResolverFactory::Job* job) { |
633 size_t erased = jobs_.erase(job); | 634 size_t erased = jobs_.erase(job); |
634 DCHECK_EQ(1u, erased); | 635 DCHECK_EQ(1u, erased); |
635 } | 636 } |
636 | 637 |
637 } // namespace net | 638 } // namespace net |
OLD | NEW |