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 #ifndef NET_HTTP_HTTP_NETWORK_SESSION_H_ | 5 #ifndef NET_HTTP_HTTP_NETWORK_SESSION_H_ |
| 6 #define NET_HTTP_HTTP_NETWORK_SESSION_H_ | 6 #define NET_HTTP_HTTP_NETWORK_SESSION_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 275 | 275 |
| 276 // Populates |*npn_protos| with protocols to be used with NPN. | 276 // Populates |*npn_protos| with protocols to be used with NPN. |
| 277 void GetNpnProtos(NextProtoVector* npn_protos) const; | 277 void GetNpnProtos(NextProtoVector* npn_protos) const; |
| 278 | 278 |
| 279 // Populates |server_config| and |proxy_config| based on this session and | 279 // Populates |server_config| and |proxy_config| based on this session and |
| 280 // |request|. | 280 // |request|. |
| 281 void GetSSLConfig(const HttpRequestInfo& request, | 281 void GetSSLConfig(const HttpRequestInfo& request, |
| 282 SSLConfig* server_config, | 282 SSLConfig* server_config, |
| 283 SSLConfig* proxy_config) const; | 283 SSLConfig* proxy_config) const; |
| 284 | 284 |
| 285 // TODO(ricea): Remove this by October 2017. | |
| 286 void IncrementActiveWebSockets() { ++active_websockets_; } | |
| 287 void DecrementActiveWebSockets() { --active_websockets_; } | |
| 288 | |
| 285 private: | 289 private: |
| 286 friend class HttpNetworkSessionPeer; | 290 friend class HttpNetworkSessionPeer; |
| 287 | 291 |
| 288 ClientSocketPoolManager* GetSocketPoolManager(SocketPoolType pool_type); | 292 ClientSocketPoolManager* GetSocketPoolManager(SocketPoolType pool_type); |
| 289 | 293 |
| 290 // Flush sockets on low memory notifications callback. | 294 // Flush sockets on low memory notifications callback. |
| 291 void OnMemoryPressure( | 295 void OnMemoryPressure( |
| 292 base::MemoryPressureListener::MemoryPressureLevel memory_pressure_level); | 296 base::MemoryPressureListener::MemoryPressureLevel memory_pressure_level); |
| 293 | 297 |
| 294 NetLog* const net_log_; | 298 NetLog* const net_log_; |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 309 std::unique_ptr<HttpStreamFactory> http_stream_factory_; | 313 std::unique_ptr<HttpStreamFactory> http_stream_factory_; |
| 310 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket_; | 314 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket_; |
| 311 std::set<HttpResponseBodyDrainer*> response_drainers_; | 315 std::set<HttpResponseBodyDrainer*> response_drainers_; |
| 312 | 316 |
| 313 NextProtoVector next_protos_; | 317 NextProtoVector next_protos_; |
| 314 bool enabled_protocols_[NUM_VALID_ALTERNATE_PROTOCOLS]; | 318 bool enabled_protocols_[NUM_VALID_ALTERNATE_PROTOCOLS]; |
| 315 | 319 |
| 316 Params params_; | 320 Params params_; |
| 317 | 321 |
| 318 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; | 322 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; |
| 323 | |
| 324 // TODO(ricea): Remove this by October 2017. | |
|
yhirano
2016/09/08 02:27:13
Do you mean Oct 2016?
Ditto for all occurrences.
Adam Rice
2016/09/08 07:22:08
Wow. Okay. Yes. I meant 2016. Fixed.
| |
| 325 int active_websockets_ = 0; | |
| 319 }; | 326 }; |
| 320 | 327 |
| 321 } // namespace net | 328 } // namespace net |
| 322 | 329 |
| 323 #endif // NET_HTTP_HTTP_NETWORK_SESSION_H_ | 330 #endif // NET_HTTP_HTTP_NETWORK_SESSION_H_ |
| OLD | NEW |