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

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

Issue 1901533002: Implementation of network level throttler. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Destroy transaction before session in QuicUploadWriteError. Created 4 years, 2 months 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 | « net/http/http_network_session.cc ('k') | net/http/http_network_session_peer.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_PEER_H_ 5 #ifndef NET_HTTP_HTTP_NETWORK_SESSION_PEER_H_
6 #define NET_HTTP_HTTP_NETWORK_SESSION_PEER_H_ 6 #define NET_HTTP_HTTP_NETWORK_SESSION_PEER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "net/base/net_export.h" 12 #include "net/base/net_export.h"
13 13
14 namespace net { 14 namespace net {
15 15
16 class ClientSocketPoolManager; 16 class ClientSocketPoolManager;
17 class HttpNetworkSession; 17 class HttpNetworkSession;
18 class HttpStreamFactory; 18 class HttpStreamFactory;
19 class NetworkThrottleManager;
19 class ProxyService; 20 class ProxyService;
20 21
21 class NET_EXPORT_PRIVATE HttpNetworkSessionPeer { 22 class NET_EXPORT_PRIVATE HttpNetworkSessionPeer {
22 public: 23 public:
23 // |session| should outlive the HttpNetworkSessionPeer. 24 // |session| should outlive the HttpNetworkSessionPeer.
24 explicit HttpNetworkSessionPeer(HttpNetworkSession* session); 25 explicit HttpNetworkSessionPeer(HttpNetworkSession* session);
25 ~HttpNetworkSessionPeer(); 26 ~HttpNetworkSessionPeer();
26 27
27 void SetClientSocketPoolManager( 28 void SetClientSocketPoolManager(
28 std::unique_ptr<ClientSocketPoolManager> socket_pool_manager); 29 std::unique_ptr<ClientSocketPoolManager> socket_pool_manager);
29 30
30 void SetHttpStreamFactory( 31 void SetHttpStreamFactory(
31 std::unique_ptr<HttpStreamFactory> http_stream_factory); 32 std::unique_ptr<HttpStreamFactory> http_stream_factory);
32 void SetHttpStreamFactoryForWebSocket( 33 void SetHttpStreamFactoryForWebSocket(
33 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket); 34 std::unique_ptr<HttpStreamFactory> http_stream_factory_for_websocket);
34 35
36 void SetNetworkStreamThrottler(
37 std::unique_ptr<NetworkThrottleManager> network_throttle_manager);
38
35 private: 39 private:
36 HttpNetworkSession* const session_; 40 HttpNetworkSession* const session_;
37 41
38 DISALLOW_COPY_AND_ASSIGN(HttpNetworkSessionPeer); 42 DISALLOW_COPY_AND_ASSIGN(HttpNetworkSessionPeer);
39 }; 43 };
40 44
41 } // namespace net 45 } // namespace net
42 46
43 #endif // NET_HTTP_HTTP_NETWORK_SESSION_PEER_H_ 47 #endif // NET_HTTP_HTTP_NETWORK_SESSION_PEER_H_
OLDNEW
« no previous file with comments | « net/http/http_network_session.cc ('k') | net/http/http_network_session_peer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698