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 // TCP cubic send side congestion algorithm, emulates the behavior of | 5 // TCP cubic send side congestion algorithm, emulates the behavior of |
6 // TCP cubic. | 6 // TCP cubic. |
7 | 7 |
8 #ifndef NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ | 8 #ifndef NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ |
9 #define NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ | 9 #define NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ |
10 | 10 |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 QuicPacketSequenceNumber sequence_number, | 53 QuicPacketSequenceNumber sequence_number, |
54 QuicByteCount bytes, | 54 QuicByteCount bytes, |
55 HasRetransmittableData is_retransmittable) OVERRIDE; | 55 HasRetransmittableData is_retransmittable) OVERRIDE; |
56 virtual void OnRetransmissionTimeout(bool packets_retransmitted) OVERRIDE; | 56 virtual void OnRetransmissionTimeout(bool packets_retransmitted) OVERRIDE; |
57 virtual void RevertRetransmissionTimeout() OVERRIDE; | 57 virtual void RevertRetransmissionTimeout() OVERRIDE; |
58 virtual QuicTime::Delta TimeUntilSend( | 58 virtual QuicTime::Delta TimeUntilSend( |
59 QuicTime now, | 59 QuicTime now, |
60 QuicByteCount bytes_in_flight, | 60 QuicByteCount bytes_in_flight, |
61 HasRetransmittableData has_retransmittable_data) const OVERRIDE; | 61 HasRetransmittableData has_retransmittable_data) const OVERRIDE; |
62 virtual QuicBandwidth BandwidthEstimate() const OVERRIDE; | 62 virtual QuicBandwidth BandwidthEstimate() const OVERRIDE; |
| 63 virtual bool HasReliableBandwidthEstimate() const OVERRIDE; |
63 virtual QuicTime::Delta RetransmissionDelay() const OVERRIDE; | 64 virtual QuicTime::Delta RetransmissionDelay() const OVERRIDE; |
64 virtual QuicByteCount GetCongestionWindow() const OVERRIDE; | 65 virtual QuicByteCount GetCongestionWindow() const OVERRIDE; |
65 // End implementation of SendAlgorithmInterface. | 66 // End implementation of SendAlgorithmInterface. |
66 | 67 |
67 private: | 68 private: |
68 friend class test::TcpCubicSenderPeer; | 69 friend class test::TcpCubicSenderPeer; |
69 | 70 |
70 // TODO(ianswett): Remove these and migrate to OnCongestionEvent. | 71 // TODO(ianswett): Remove these and migrate to OnCongestionEvent. |
71 void OnPacketAcked(QuicPacketSequenceNumber acked_sequence_number, | 72 void OnPacketAcked(QuicPacketSequenceNumber acked_sequence_number, |
72 QuicByteCount acked_bytes, | 73 QuicByteCount acked_bytes, |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 | 135 |
135 // Maximum number of outstanding packets for tcp. | 136 // Maximum number of outstanding packets for tcp. |
136 QuicTcpCongestionWindow max_tcp_congestion_window_; | 137 QuicTcpCongestionWindow max_tcp_congestion_window_; |
137 | 138 |
138 DISALLOW_COPY_AND_ASSIGN(TcpCubicSender); | 139 DISALLOW_COPY_AND_ASSIGN(TcpCubicSender); |
139 }; | 140 }; |
140 | 141 |
141 } // namespace net | 142 } // namespace net |
142 | 143 |
143 #endif // NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ | 144 #endif // NET_QUIC_CONGESTION_CONTROL_TCP_CUBIC_SENDER_H_ |
OLD | NEW |