OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef NET_QUIC_CONGESTION_CONTROL_TCP_LOSS_ALGORITHM_H_ |
| 6 #define NET_QUIC_CONGESTION_CONTROL_TCP_LOSS_ALGORITHM_H_ |
| 7 |
| 8 #include <algorithm> |
| 9 #include <map> |
| 10 |
| 11 #include "base/basictypes.h" |
| 12 #include "net/quic/congestion_control/loss_detection_interface.h" |
| 13 #include "net/quic/quic_protocol.h" |
| 14 #include "net/quic/quic_time.h" |
| 15 #include "net/quic/quic_unacked_packet_map.h" |
| 16 |
| 17 namespace net { |
| 18 |
| 19 // Class which implement's TCP's approach of detecting loss when 3 nacks have |
| 20 // been received for a packet. Also implements TCP's early retransmit(RFC5827). |
| 21 class NET_EXPORT_PRIVATE TCPLossAlgorithm : public LossDetectionInterface { |
| 22 public: |
| 23 TCPLossAlgorithm(); |
| 24 virtual ~TCPLossAlgorithm() {} |
| 25 |
| 26 // Uses nack counts to decide when packets are lost. |
| 27 virtual SequenceNumberSet DetectLostPackets( |
| 28 const QuicUnackedPacketMap& unacked_packets, |
| 29 const QuicTime& time, |
| 30 QuicPacketSequenceNumber largest_observed, |
| 31 QuicTime::Delta srtt) OVERRIDE; |
| 32 }; |
| 33 |
| 34 } // namespace net |
| 35 |
| 36 #endif // NET_QUIC_CONGESTION_CONTROL_TCP_LOSS_ALGORITHM_H_ |
OLD | NEW |