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 // ClientSocketPoolManager manages access to all ClientSocketPools. It's a | 5 // ClientSocketPoolManager manages access to all ClientSocketPools. It's a |
6 // simple container for all of them. Most importantly, it handles the lifetime | 6 // simple container for all of them. Most importantly, it handles the lifetime |
7 // and destruction order properly. | 7 // and destruction order properly. |
8 | 8 |
9 #ifndef NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ | 9 #ifndef NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ |
10 #define NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ | 10 #define NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 const SSLConfig& ssl_config_for_origin, | 101 const SSLConfig& ssl_config_for_origin, |
102 const SSLConfig& ssl_config_for_proxy, | 102 const SSLConfig& ssl_config_for_proxy, |
103 PrivacyMode privacy_mode, | 103 PrivacyMode privacy_mode, |
104 const BoundNetLog& net_log, | 104 const BoundNetLog& net_log, |
105 ClientSocketHandle* socket_handle, | 105 ClientSocketHandle* socket_handle, |
106 const OnHostResolutionCallback& resolution_callback, | 106 const OnHostResolutionCallback& resolution_callback, |
107 const CompletionCallback& callback); | 107 const CompletionCallback& callback); |
108 | 108 |
109 // A helper method that uses the passed in proxy information to initialize a | 109 // A helper method that uses the passed in proxy information to initialize a |
110 // ClientSocketHandle with the relevant socket pool. Use this method for | 110 // ClientSocketHandle with the relevant socket pool. Use this method for |
| 111 // HTTP/HTTPS requests for WebSocket handshake. |
| 112 // |ssl_config_for_origin| is only used if the request |
| 113 // uses SSL and |ssl_config_for_proxy| is used if the proxy server is HTTPS. |
| 114 // |resolution_callback| will be invoked after the the hostname is |
| 115 // resolved. If |resolution_callback| does not return OK, then the |
| 116 // connection will be aborted with that value. |
| 117 int InitSocketHandleForWebSocketRequest( |
| 118 const GURL& request_url, |
| 119 const HttpRequestHeaders& request_extra_headers, |
| 120 int request_load_flags, |
| 121 RequestPriority request_priority, |
| 122 HttpNetworkSession* session, |
| 123 const ProxyInfo& proxy_info, |
| 124 bool force_spdy_over_ssl, |
| 125 bool want_spdy_over_npn, |
| 126 const SSLConfig& ssl_config_for_origin, |
| 127 const SSLConfig& ssl_config_for_proxy, |
| 128 PrivacyMode privacy_mode, |
| 129 const BoundNetLog& net_log, |
| 130 ClientSocketHandle* socket_handle, |
| 131 const OnHostResolutionCallback& resolution_callback, |
| 132 const CompletionCallback& callback); |
| 133 |
| 134 // A helper method that uses the passed in proxy information to initialize a |
| 135 // ClientSocketHandle with the relevant socket pool. Use this method for |
111 // a raw socket connection to a host-port pair (that needs to tunnel through | 136 // a raw socket connection to a host-port pair (that needs to tunnel through |
112 // the proxies). | 137 // the proxies). |
113 NET_EXPORT int InitSocketHandleForRawConnect( | 138 NET_EXPORT int InitSocketHandleForRawConnect( |
114 const HostPortPair& host_port_pair, | 139 const HostPortPair& host_port_pair, |
115 HttpNetworkSession* session, | 140 HttpNetworkSession* session, |
116 const ProxyInfo& proxy_info, | 141 const ProxyInfo& proxy_info, |
117 const SSLConfig& ssl_config_for_origin, | 142 const SSLConfig& ssl_config_for_origin, |
118 const SSLConfig& ssl_config_for_proxy, | 143 const SSLConfig& ssl_config_for_proxy, |
119 PrivacyMode privacy_mode, | 144 PrivacyMode privacy_mode, |
120 const BoundNetLog& net_log, | 145 const BoundNetLog& net_log, |
(...skipping 13 matching lines...) Expand all Loading... |
134 bool want_spdy_over_npn, | 159 bool want_spdy_over_npn, |
135 const SSLConfig& ssl_config_for_origin, | 160 const SSLConfig& ssl_config_for_origin, |
136 const SSLConfig& ssl_config_for_proxy, | 161 const SSLConfig& ssl_config_for_proxy, |
137 PrivacyMode privacy_mode, | 162 PrivacyMode privacy_mode, |
138 const BoundNetLog& net_log, | 163 const BoundNetLog& net_log, |
139 int num_preconnect_streams); | 164 int num_preconnect_streams); |
140 | 165 |
141 } // namespace net | 166 } // namespace net |
142 | 167 |
143 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ | 168 #endif // NET_SOCKET_CLIENT_SOCKET_POOL_MANAGER_H_ |
OLD | NEW |