| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ | 5 #ifndef NET_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ |
| 6 #define NET_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ | 6 #define NET_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ |
| 7 | 7 |
| 8 #include "net/quic/test_tools/quic_test_writer.h" | |
| 9 #include "net/tools/quic/quic_dispatcher.h" | 8 #include "net/tools/quic/quic_dispatcher.h" |
| 10 | 9 |
| 11 namespace net { | 10 namespace net { |
| 12 namespace tools { | 11 namespace tools { |
| 12 |
| 13 class QuicPacketWriterWrapper; |
| 14 |
| 13 namespace test { | 15 namespace test { |
| 14 | 16 |
| 15 class QuicDispatcherPeer { | 17 class QuicDispatcherPeer { |
| 16 public: | 18 public: |
| 17 static void SetTimeWaitListManager( | 19 static void SetTimeWaitListManager( |
| 18 QuicDispatcher* dispatcher, | 20 QuicDispatcher* dispatcher, |
| 19 QuicTimeWaitListManager* time_wait_list_manager); | 21 QuicTimeWaitListManager* time_wait_list_manager); |
| 20 | 22 |
| 23 // Injects |writer| into |dispatcher| beneath the top-level wrapper (to avoid |
| 24 // messing up existing connections). |
| 21 static void UseWriter(QuicDispatcher* dispatcher, | 25 static void UseWriter(QuicDispatcher* dispatcher, |
| 22 net::test::QuicTestWriter* writer); | 26 QuicPacketWriterWrapper* writer); |
| 23 | 27 |
| 24 static QuicPacketWriter* GetWriter(QuicDispatcher* dispatcher); | 28 static QuicPacketWriterWrapper* GetWriter(QuicDispatcher* dispatcher); |
| 25 | 29 |
| 26 static QuicEpollConnectionHelper* GetHelper(QuicDispatcher* dispatcher); | 30 static QuicEpollConnectionHelper* GetHelper(QuicDispatcher* dispatcher); |
| 27 }; | 31 }; |
| 28 | 32 |
| 29 } // namespace test | 33 } // namespace test |
| 30 } // namespace tools | 34 } // namespace tools |
| 31 } // namespace net | 35 } // namespace net |
| 32 | 36 |
| 33 #endif // NET_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ | 37 #endif // NET_TOOLS_QUIC_TEST_TOOLS_QUIC_DISPATCHER_PEER_H_ |
| OLD | NEW |