Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(319)

Side by Side Diff: net/http/http_network_session.h

Issue 2521573006: Server push cancellation: change the ownership of ServerPushDelegate to HttpNetworkSession. (Closed)
Patch Set: Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | net/http/http_network_session.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 std::unique_ptr<base::Value> QuicInfoToValue() const; 263 std::unique_ptr<base::Value> QuicInfoToValue() const;
264 264
265 void CloseAllConnections(); 265 void CloseAllConnections();
266 void CloseIdleConnections(); 266 void CloseIdleConnections();
267 267
268 // Returns the original Params used to construct this session. 268 // Returns the original Params used to construct this session.
269 const Params& params() const { return params_; } 269 const Params& params() const { return params_; }
270 270
271 bool IsProtocolEnabled(NextProto protocol) const; 271 bool IsProtocolEnabled(NextProto protocol) const;
272 272
273 // Takes ownership of |push_delegate| and pass the references to
274 // |quic_stream_factory_| and |spdy_session_pool_|.
Ryan Hamilton 2016/11/23 04:22:41 No reason to mention ownership, since the argument
Zhongyi Shi 2016/11/23 06:20:02 Done.
275 void SetServerPushDelegate(std::unique_ptr<ServerPushDelegate> push_delegate);
276
273 // Populates |*alpn_protos| with protocols to be used with ALPN. 277 // Populates |*alpn_protos| with protocols to be used with ALPN.
274 void GetAlpnProtos(NextProtoVector* alpn_protos) const; 278 void GetAlpnProtos(NextProtoVector* alpn_protos) const;
275 279
276 // Populates |server_config| and |proxy_config| based on this session and 280 // Populates |server_config| and |proxy_config| based on this session and
277 // |request|. 281 // |request|.
278 void GetSSLConfig(const HttpRequestInfo& request, 282 void GetSSLConfig(const HttpRequestInfo& request,
279 SSLConfig* server_config, 283 SSLConfig* server_config,
280 SSLConfig* proxy_config) const; 284 SSLConfig* proxy_config) const;
281 285
282 private: 286 private:
(...skipping 14 matching lines...) Expand all
297 HttpAuthHandlerFactory* const http_auth_handler_factory_; 301 HttpAuthHandlerFactory* const http_auth_handler_factory_;
298 302
299 // Not const since it's modified by HttpNetworkSessionPeer for testing. 303 // Not const since it's modified by HttpNetworkSessionPeer for testing.
300 ProxyService* proxy_service_; 304 ProxyService* proxy_service_;
301 const scoped_refptr<SSLConfigService> ssl_config_service_; 305 const scoped_refptr<SSLConfigService> ssl_config_service_;
302 306
303 HttpAuthCache http_auth_cache_; 307 HttpAuthCache http_auth_cache_;
304 SSLClientAuthCache ssl_client_auth_cache_; 308 SSLClientAuthCache ssl_client_auth_cache_;
305 std::unique_ptr<ClientSocketPoolManager> normal_socket_pool_manager_; 309 std::unique_ptr<ClientSocketPoolManager> normal_socket_pool_manager_;
306 std::unique_ptr<ClientSocketPoolManager> websocket_socket_pool_manager_; 310 std::unique_ptr<ClientSocketPoolManager> websocket_socket_pool_manager_;
311 std::unique_ptr<ServerPushDelegate> push_delegate_;
307 QuicStreamFactory quic_stream_factory_; 312 QuicStreamFactory quic_stream_factory_;
308 SpdySessionPool spdy_session_pool_; 313 SpdySessionPool spdy_session_pool_;
309 std::unique_ptr<HttpStreamFactory> http_stream_factory_; 314 std::unique_ptr<HttpStreamFactory> http_stream_factory_;
310 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket_; 315 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket_;
311 std::map<HttpResponseBodyDrainer*, std::unique_ptr<HttpResponseBodyDrainer>> 316 std::map<HttpResponseBodyDrainer*, std::unique_ptr<HttpResponseBodyDrainer>>
312 response_drainers_; 317 response_drainers_;
313 std::unique_ptr<NetworkThrottleManager> network_stream_throttler_; 318 std::unique_ptr<NetworkThrottleManager> network_stream_throttler_;
314 319
315 NextProtoVector next_protos_; 320 NextProtoVector next_protos_;
316 321
317 Params params_; 322 Params params_;
318 323
319 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_; 324 std::unique_ptr<base::MemoryPressureListener> memory_pressure_listener_;
320 }; 325 };
321 326
322 } // namespace net 327 } // namespace net
323 328
324 #endif // NET_HTTP_HTTP_NETWORK_SESSION_H_ 329 #endif // NET_HTTP_HTTP_NETWORK_SESSION_H_
OLDNEW
« no previous file with comments | « no previous file | net/http/http_network_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698