OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ | 5 #ifndef NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ |
6 #define NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ | 6 #define NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/task_runner.h" | 12 #include "base/task_runner.h" |
13 #include "net/base/host_port_pair.h" | 13 #include "net/base/host_port_pair.h" |
14 #include "net/base/privacy_mode.h" | 14 #include "net/base/privacy_mode.h" |
15 #include "net/quic/core/quic_packets.h" | 15 #include "net/quic/core/quic_packets.h" |
16 #include "net/quic/core/quic_server_id.h" | 16 #include "net/quic/core/quic_server_id.h" |
17 #include "net/quic/core/quic_time.h" | 17 #include "net/quic/core/quic_time.h" |
18 | 18 |
19 namespace net { | 19 namespace net { |
20 | 20 |
21 class NetLogWithSource; | 21 class NetLogWithSource; |
| 22 class QuicAlarmFactory; |
| 23 class QuicChromiumClientSession; |
| 24 class QuicClientPushPromiseIndex; |
22 class QuicConfig; | 25 class QuicConfig; |
23 class QuicCryptoClientConfig; | 26 class QuicCryptoClientConfig; |
24 class QuicHttpStream; | 27 class QuicHttpStream; |
25 class QuicStreamFactory; | 28 class QuicStreamFactory; |
26 class QuicChromiumClientSession; | |
27 class QuicClientPushPromiseIndex; | |
28 | 29 |
29 namespace test { | 30 namespace test { |
30 | 31 |
31 class QuicStreamFactoryPeer { | 32 class QuicStreamFactoryPeer { |
32 public: | 33 public: |
33 static const QuicConfig* GetConfig(QuicStreamFactory* factory); | 34 static const QuicConfig* GetConfig(QuicStreamFactory* factory); |
34 | 35 |
35 static QuicCryptoClientConfig* GetCryptoConfig(QuicStreamFactory* factory); | 36 static QuicCryptoClientConfig* GetCryptoConfig(QuicStreamFactory* factory); |
36 | 37 |
37 static bool HasActiveSession(QuicStreamFactory* factory, | 38 static bool HasActiveSession(QuicStreamFactory* factory, |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 | 95 |
95 // Creates a dummy QUIC server config and caches it. | 96 // Creates a dummy QUIC server config and caches it. |
96 static void CacheDummyServerConfig(QuicStreamFactory* factory, | 97 static void CacheDummyServerConfig(QuicStreamFactory* factory, |
97 const QuicServerId& quic_server_id); | 98 const QuicServerId& quic_server_id); |
98 | 99 |
99 static QuicClientPushPromiseIndex* GetPushPromiseIndex( | 100 static QuicClientPushPromiseIndex* GetPushPromiseIndex( |
100 QuicStreamFactory* factory); | 101 QuicStreamFactory* factory); |
101 | 102 |
102 static int GetNumPushStreamsCreated(QuicStreamFactory* factory); | 103 static int GetNumPushStreamsCreated(QuicStreamFactory* factory); |
103 | 104 |
| 105 static void SetAlarmFactory(QuicStreamFactory* factory, |
| 106 std::unique_ptr<QuicAlarmFactory> alarm_factory); |
| 107 |
104 private: | 108 private: |
105 DISALLOW_COPY_AND_ASSIGN(QuicStreamFactoryPeer); | 109 DISALLOW_COPY_AND_ASSIGN(QuicStreamFactoryPeer); |
106 }; | 110 }; |
107 | 111 |
108 } // namespace test | 112 } // namespace test |
109 } // namespace net | 113 } // namespace net |
110 | 114 |
111 #endif // NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ | 115 #endif // NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ |
OLD | NEW |