| 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_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ | 5 #ifndef NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ |
| 6 #define NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ | 6 #define NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <type_traits> | 10 #include <type_traits> |
| 11 | 11 |
| 12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
| 13 #include "base/macros.h" | 13 #include "base/macros.h" |
| 14 #include "base/memory/ref_counted.h" | 14 #include "base/memory/ref_counted.h" |
| 15 #include "base/threading/non_thread_safe.h" | 15 #include "base/threading/non_thread_safe.h" |
| 16 #include "net/cert/cert_database.h" | 16 #include "net/cert/cert_database.h" |
| 17 #include "net/http/http_network_session.h" | 17 #include "net/http/http_network_session.h" |
| 18 #include "net/socket/client_socket_pool_manager.h" | 18 #include "net/socket/client_socket_pool_manager.h" |
| 19 | 19 |
| 20 namespace base { |
| 21 namespace trace_event { |
| 22 class MemoryAllocatorDump; |
| 23 } |
| 24 } |
| 25 |
| 20 namespace net { | 26 namespace net { |
| 21 | 27 |
| 22 class CertVerifier; | 28 class CertVerifier; |
| 23 class ChannelIDService; | 29 class ChannelIDService; |
| 24 class ClientSocketFactory; | 30 class ClientSocketFactory; |
| 25 class CTVerifier; | 31 class CTVerifier; |
| 26 class HttpProxyClientSocketPool; | 32 class HttpProxyClientSocketPool; |
| 27 class HostResolver; | 33 class HostResolver; |
| 28 class NetLog; | 34 class NetLog; |
| 29 class SocketPerformanceWatcherFactory; | 35 class SocketPerformanceWatcherFactory; |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 | 73 |
| 68 SSLClientSocketPool* GetSocketPoolForSSLWithProxy( | 74 SSLClientSocketPool* GetSocketPoolForSSLWithProxy( |
| 69 const HostPortPair& proxy_server) override; | 75 const HostPortPair& proxy_server) override; |
| 70 | 76 |
| 71 // Creates a Value summary of the state of the socket pools. | 77 // Creates a Value summary of the state of the socket pools. |
| 72 std::unique_ptr<base::Value> SocketPoolInfoToValue() const override; | 78 std::unique_ptr<base::Value> SocketPoolInfoToValue() const override; |
| 73 | 79 |
| 74 // CertDatabase::Observer methods: | 80 // CertDatabase::Observer methods: |
| 75 void OnCertDBChanged(const X509Certificate* cert) override; | 81 void OnCertDBChanged(const X509Certificate* cert) override; |
| 76 | 82 |
| 83 void PopulateAllocatorDump( |
| 84 base::trace_event::MemoryAllocatorDump* dump) const override; |
| 85 |
| 77 private: | 86 private: |
| 78 using TransportSocketPoolMap = | 87 using TransportSocketPoolMap = |
| 79 std::map<HostPortPair, std::unique_ptr<TransportClientSocketPool>>; | 88 std::map<HostPortPair, std::unique_ptr<TransportClientSocketPool>>; |
| 80 using SOCKSSocketPoolMap = | 89 using SOCKSSocketPoolMap = |
| 81 std::map<HostPortPair, std::unique_ptr<SOCKSClientSocketPool>>; | 90 std::map<HostPortPair, std::unique_ptr<SOCKSClientSocketPool>>; |
| 82 using HTTPProxySocketPoolMap = | 91 using HTTPProxySocketPoolMap = |
| 83 std::map<HostPortPair, std::unique_ptr<HttpProxyClientSocketPool>>; | 92 std::map<HostPortPair, std::unique_ptr<HttpProxyClientSocketPool>>; |
| 84 using SSLSocketPoolMap = | 93 using SSLSocketPoolMap = |
| 85 std::map<HostPortPair, std::unique_ptr<SSLClientSocketPool>>; | 94 std::map<HostPortPair, std::unique_ptr<SSLClientSocketPool>>; |
| 86 | 95 |
| (...skipping 21 matching lines...) Expand all Loading... |
| 108 SSLSocketPoolMap ssl_socket_pools_for_https_proxies_; | 117 SSLSocketPoolMap ssl_socket_pools_for_https_proxies_; |
| 109 HTTPProxySocketPoolMap http_proxy_socket_pools_; | 118 HTTPProxySocketPoolMap http_proxy_socket_pools_; |
| 110 SSLSocketPoolMap ssl_socket_pools_for_proxies_; | 119 SSLSocketPoolMap ssl_socket_pools_for_proxies_; |
| 111 | 120 |
| 112 DISALLOW_COPY_AND_ASSIGN(ClientSocketPoolManagerImpl); | 121 DISALLOW_COPY_AND_ASSIGN(ClientSocketPoolManagerImpl); |
| 113 }; | 122 }; |
| 114 | 123 |
| 115 } // namespace net | 124 } // namespace net |
| 116 | 125 |
| 117 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ | 126 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_IMPL_H_ |
| OLD | NEW |