OLD | NEW |
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 #include "net/quic/test_tools/quic_connection_peer.h" | 5 #include "net/quic/test_tools/quic_connection_peer.h" |
6 | 6 |
7 #include "base/stl_util.h" | 7 #include "base/stl_util.h" |
8 #include "net/quic/core/congestion_control/send_algorithm_interface.h" | 8 #include "net/quic/core/congestion_control/send_algorithm_interface.h" |
9 #include "net/quic/core/quic_multipath_sent_packet_manager.h" | 9 #include "net/quic/core/quic_multipath_sent_packet_manager.h" |
10 #include "net/quic/core/quic_packet_writer.h" | 10 #include "net/quic/core/quic_packet_writer.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 GetSentPacketManager(connection, path_id) | 29 GetSentPacketManager(connection, path_id) |
30 ->send_algorithm_.reset(send_algorithm); | 30 ->send_algorithm_.reset(send_algorithm); |
31 GetSentPacketManager(connection, path_id)->using_inline_pacing_ = false; | 31 GetSentPacketManager(connection, path_id)->using_inline_pacing_ = false; |
32 } | 32 } |
33 | 33 |
34 // static | 34 // static |
35 void QuicConnectionPeer::SetLossAlgorithm( | 35 void QuicConnectionPeer::SetLossAlgorithm( |
36 QuicConnection* connection, | 36 QuicConnection* connection, |
37 QuicPathId path_id, | 37 QuicPathId path_id, |
38 LossDetectionInterface* loss_algorithm) { | 38 LossDetectionInterface* loss_algorithm) { |
39 GetSentPacketManager(connection, path_id) | 39 GetSentPacketManager(connection, path_id)->loss_algorithm_ = loss_algorithm; |
40 ->loss_algorithm_.reset(loss_algorithm); | |
41 } | 40 } |
42 | 41 |
43 // static | 42 // static |
44 const QuicFrame QuicConnectionPeer::GetUpdatedAckFrame( | 43 const QuicFrame QuicConnectionPeer::GetUpdatedAckFrame( |
45 QuicConnection* connection) { | 44 QuicConnection* connection) { |
46 return connection->GetUpdatedAckFrame(); | 45 return connection->GetUpdatedAckFrame(); |
47 } | 46 } |
48 | 47 |
49 // static | 48 // static |
50 void QuicConnectionPeer::PopulateStopWaitingFrame( | 49 void QuicConnectionPeer::PopulateStopWaitingFrame( |
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
299 bool QuicConnectionPeer::HasRetransmittableFrames( | 298 bool QuicConnectionPeer::HasRetransmittableFrames( |
300 QuicConnection* connection, | 299 QuicConnection* connection, |
301 QuicPathId path_id, | 300 QuicPathId path_id, |
302 QuicPacketNumber packet_number) { | 301 QuicPacketNumber packet_number) { |
303 return QuicSentPacketManagerPeer::HasRetransmittableFrames( | 302 return QuicSentPacketManagerPeer::HasRetransmittableFrames( |
304 GetSentPacketManager(connection, path_id), packet_number); | 303 GetSentPacketManager(connection, path_id), packet_number); |
305 } | 304 } |
306 | 305 |
307 } // namespace test | 306 } // namespace test |
308 } // namespace net | 307 } // namespace net |
OLD | NEW |