| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_UNACKED_PACKET_MAP_H_ | 5 #ifndef NET_QUIC_QUIC_UNACKED_PACKET_MAP_H_ |
| 6 #define NET_QUIC_QUIC_UNACKED_PACKET_MAP_H_ | 6 #define NET_QUIC_QUIC_UNACKED_PACKET_MAP_H_ |
| 7 | 7 |
| 8 #include <deque> | 8 #include <deque> |
| 9 | 9 |
| 10 #include "net/quic/quic_protocol.h" | 10 #include "net/quic/quic_protocol.h" |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 // measurement, and it's old enough that is unlikely to ever happen. | 146 // measurement, and it's old enough that is unlikely to ever happen. |
| 147 bool IsPacketRemovable(QuicPacketSequenceNumber sequence_number, | 147 bool IsPacketRemovable(QuicPacketSequenceNumber sequence_number, |
| 148 const TransmissionInfo& info) const; | 148 const TransmissionInfo& info) const; |
| 149 | 149 |
| 150 QuicPacketSequenceNumber largest_sent_packet_; | 150 QuicPacketSequenceNumber largest_sent_packet_; |
| 151 QuicPacketSequenceNumber largest_observed_; | 151 QuicPacketSequenceNumber largest_observed_; |
| 152 | 152 |
| 153 // Newly serialized retransmittable and fec packets are added to this map, | 153 // Newly serialized retransmittable and fec packets are added to this map, |
| 154 // which contains owning pointers to any contained frames. If a packet is | 154 // which contains owning pointers to any contained frames. If a packet is |
| 155 // retransmitted, this map will contain entries for both the old and the new | 155 // retransmitted, this map will contain entries for both the old and the new |
| 156 // packet. The old packet's retransmittable frames entry will be NULL, while | 156 // packet. The old packet's retransmittable frames entry will be nullptr, |
| 157 // the new packet's entry will contain the frames to retransmit. | 157 // while the new packet's entry will contain the frames to retransmit. |
| 158 // If the old packet is acked before the new packet, then the old entry will | 158 // If the old packet is acked before the new packet, then the old entry will |
| 159 // be removed from the map and the new entry's retransmittable frames will be | 159 // be removed from the map and the new entry's retransmittable frames will be |
| 160 // set to NULL. | 160 // set to nullptr. |
| 161 UnackedPacketMap unacked_packets_; | 161 UnackedPacketMap unacked_packets_; |
| 162 // The packet at the 0th index of unacked_packets_. | 162 // The packet at the 0th index of unacked_packets_. |
| 163 QuicPacketSequenceNumber least_unacked_; | 163 QuicPacketSequenceNumber least_unacked_; |
| 164 | 164 |
| 165 size_t bytes_in_flight_; | 165 size_t bytes_in_flight_; |
| 166 // Number of retransmittable crypto handshake packets. | 166 // Number of retransmittable crypto handshake packets. |
| 167 size_t pending_crypto_packet_count_; | 167 size_t pending_crypto_packet_count_; |
| 168 | 168 |
| 169 DISALLOW_COPY_AND_ASSIGN(QuicUnackedPacketMap); | 169 DISALLOW_COPY_AND_ASSIGN(QuicUnackedPacketMap); |
| 170 }; | 170 }; |
| 171 | 171 |
| 172 } // namespace net | 172 } // namespace net |
| 173 | 173 |
| 174 #endif // NET_QUIC_QUIC_UNACKED_PACKET_MAP_H_ | 174 #endif // NET_QUIC_QUIC_UNACKED_PACKET_MAP_H_ |
| OLD | NEW |