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_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 5 #ifndef NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
6 #define NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 6 #define NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <utility> | 10 #include <utility> |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 void SetHandshakeConfirmed() { handshake_confirmed_ = true; } | 104 void SetHandshakeConfirmed() { handshake_confirmed_ = true; } |
105 | 105 |
106 // Processes the incoming ack. | 106 // Processes the incoming ack. |
107 void OnIncomingAck(const QuicAckFrame& ack_frame, | 107 void OnIncomingAck(const QuicAckFrame& ack_frame, |
108 QuicTime ack_receive_time); | 108 QuicTime ack_receive_time); |
109 | 109 |
110 // Returns true if the non-FEC packet |sequence_number| is unacked. | 110 // Returns true if the non-FEC packet |sequence_number| is unacked. |
111 bool IsUnacked(QuicPacketSequenceNumber sequence_number) const; | 111 bool IsUnacked(QuicPacketSequenceNumber sequence_number) const; |
112 | 112 |
113 // Requests retransmission of all unacked packets of |retransmission_type|. | 113 // Requests retransmission of all unacked packets of |retransmission_type|. |
| 114 // The behavior of this method depends on the value of |retransmission_type|: |
| 115 // ALL_UNACKED_RETRANSMISSION - All unacked packets will be retransmitted. |
| 116 // This can happen, for example, after a version negotiation packet has been |
| 117 // received and all packets needs to be retransmitted with the new version. |
| 118 // ALL_INITIAL_RETRANSMISSION - Only initially encrypted packets will be |
| 119 // retransmitted. This can happen, for example, when a CHLO has been rejected |
| 120 // and the previously encrypted data needs to be encrypted with a new key. |
114 void RetransmitUnackedPackets(TransmissionType retransmission_type); | 121 void RetransmitUnackedPackets(TransmissionType retransmission_type); |
115 | 122 |
116 // Retransmits the oldest pending packet there is still a tail loss probe | 123 // Retransmits the oldest pending packet there is still a tail loss probe |
117 // pending. Invoked after OnRetransmissionTimeout. | 124 // pending. Invoked after OnRetransmissionTimeout. |
118 bool MaybeRetransmitTailLossProbe(); | 125 bool MaybeRetransmitTailLossProbe(); |
119 | 126 |
120 // Removes the retransmittable frames from all unencrypted packets to ensure | 127 // Removes the retransmittable frames from all unencrypted packets to ensure |
121 // they don't get retransmitted. | 128 // they don't get retransmitted. |
122 void NeuterUnencryptedPackets(); | 129 void NeuterUnencryptedPackets(); |
123 | 130 |
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
392 // Records bandwidth from server to client in normal operation, over periods | 399 // Records bandwidth from server to client in normal operation, over periods |
393 // of time with no loss events. | 400 // of time with no loss events. |
394 QuicSustainedBandwidthRecorder sustained_bandwidth_recorder_; | 401 QuicSustainedBandwidthRecorder sustained_bandwidth_recorder_; |
395 | 402 |
396 DISALLOW_COPY_AND_ASSIGN(QuicSentPacketManager); | 403 DISALLOW_COPY_AND_ASSIGN(QuicSentPacketManager); |
397 }; | 404 }; |
398 | 405 |
399 } // namespace net | 406 } // namespace net |
400 | 407 |
401 #endif // NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ | 408 #endif // NET_QUIC_QUIC_SENT_PACKET_MANAGER_H_ |
OLD | NEW |