| 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 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 | 97 |
| 97 // Creates a dummy QUIC server config and caches it. | 98 // Creates a dummy QUIC server config and caches it. |
| 98 static void CacheDummyServerConfig(QuicStreamFactory* factory, | 99 static void CacheDummyServerConfig(QuicStreamFactory* factory, |
| 99 const QuicServerId& quic_server_id); | 100 const QuicServerId& quic_server_id); |
| 100 | 101 |
| 101 static QuicClientPushPromiseIndex* GetPushPromiseIndex( | 102 static QuicClientPushPromiseIndex* GetPushPromiseIndex( |
| 102 QuicStreamFactory* factory); | 103 QuicStreamFactory* factory); |
| 103 | 104 |
| 104 static int GetNumPushStreamsCreated(QuicStreamFactory* factory); | 105 static int GetNumPushStreamsCreated(QuicStreamFactory* factory); |
| 105 | 106 |
| 107 static void SetAlarmFactory(QuicStreamFactory* factory, |
| 108 std::unique_ptr<QuicAlarmFactory> alarm_factory); |
| 109 |
| 106 private: | 110 private: |
| 107 DISALLOW_COPY_AND_ASSIGN(QuicStreamFactoryPeer); | 111 DISALLOW_COPY_AND_ASSIGN(QuicStreamFactoryPeer); |
| 108 }; | 112 }; |
| 109 | 113 |
| 110 } // namespace test | 114 } // namespace test |
| 111 } // namespace net | 115 } // namespace net |
| 112 | 116 |
| 113 #endif // NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ | 117 #endif // NET_QUIC_CHROMIUM_QUIC_STREAM_FACTORY_PEER_H_ |
| OLD | NEW |