| 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 #ifndef NET_QUIC_QUIC_PROTOCOL_H_ | 5 #ifndef NET_QUIC_QUIC_PROTOCOL_H_ |
| 6 #define NET_QUIC_QUIC_PROTOCOL_H_ | 6 #define NET_QUIC_QUIC_PROTOCOL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 1275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1286 const char* encrypted_buffer; | 1286 const char* encrypted_buffer; |
| 1287 QuicPacketLength encrypted_length; | 1287 QuicPacketLength encrypted_length; |
| 1288 QuicFrames retransmittable_frames; | 1288 QuicFrames retransmittable_frames; |
| 1289 IsHandshake has_crypto_handshake; | 1289 IsHandshake has_crypto_handshake; |
| 1290 bool needs_padding; | 1290 bool needs_padding; |
| 1291 QuicPathId path_id; | 1291 QuicPathId path_id; |
| 1292 QuicPacketNumber packet_number; | 1292 QuicPacketNumber packet_number; |
| 1293 QuicPacketNumberLength packet_number_length; | 1293 QuicPacketNumberLength packet_number_length; |
| 1294 EncryptionLevel encryption_level; | 1294 EncryptionLevel encryption_level; |
| 1295 QuicPacketEntropyHash entropy_hash; | 1295 QuicPacketEntropyHash entropy_hash; |
| 1296 bool is_fec_packet; | |
| 1297 bool has_ack; | 1296 bool has_ack; |
| 1298 bool has_stop_waiting; | 1297 bool has_stop_waiting; |
| 1299 QuicPacketNumber original_packet_number; | 1298 QuicPacketNumber original_packet_number; |
| 1300 TransmissionType transmission_type; | 1299 TransmissionType transmission_type; |
| 1301 | 1300 |
| 1302 // Optional notifiers which will be informed when this packet has been ACKed. | 1301 // Optional notifiers which will be informed when this packet has been ACKed. |
| 1303 std::list<AckListenerWrapper> listeners; | 1302 std::list<AckListenerWrapper> listeners; |
| 1304 }; | 1303 }; |
| 1305 | 1304 |
| 1306 struct NET_EXPORT_PRIVATE TransmissionInfo { | 1305 struct NET_EXPORT_PRIVATE TransmissionInfo { |
| 1307 // Used by STL when assigning into a map. | 1306 // Used by STL when assigning into a map. |
| 1308 TransmissionInfo(); | 1307 TransmissionInfo(); |
| 1309 | 1308 |
| 1310 // Constructs a Transmission with a new all_transmissions set | 1309 // Constructs a Transmission with a new all_transmissions set |
| 1311 // containing |packet_number|. | 1310 // containing |packet_number|. |
| 1312 TransmissionInfo(EncryptionLevel level, | 1311 TransmissionInfo(EncryptionLevel level, |
| 1313 QuicPacketNumberLength packet_number_length, | 1312 QuicPacketNumberLength packet_number_length, |
| 1314 TransmissionType transmission_type, | 1313 TransmissionType transmission_type, |
| 1315 QuicTime sent_time, | 1314 QuicTime sent_time, |
| 1316 QuicPacketLength bytes_sent, | 1315 QuicPacketLength bytes_sent, |
| 1317 bool is_fec_packet, | |
| 1318 bool has_crypto_handshake, | 1316 bool has_crypto_handshake, |
| 1319 bool needs_padding); | 1317 bool needs_padding); |
| 1320 | 1318 |
| 1321 TransmissionInfo(const TransmissionInfo& other); | 1319 TransmissionInfo(const TransmissionInfo& other); |
| 1322 | 1320 |
| 1323 ~TransmissionInfo(); | 1321 ~TransmissionInfo(); |
| 1324 | 1322 |
| 1325 QuicFrames retransmittable_frames; | 1323 QuicFrames retransmittable_frames; |
| 1326 EncryptionLevel encryption_level; | 1324 EncryptionLevel encryption_level; |
| 1327 QuicPacketNumberLength packet_number_length; | 1325 QuicPacketNumberLength packet_number_length; |
| 1328 QuicPacketLength bytes_sent; | 1326 QuicPacketLength bytes_sent; |
| 1329 uint16_t nack_count; | 1327 uint16_t nack_count; |
| 1330 QuicTime sent_time; | 1328 QuicTime sent_time; |
| 1331 // Reason why this packet was transmitted. | 1329 // Reason why this packet was transmitted. |
| 1332 TransmissionType transmission_type; | 1330 TransmissionType transmission_type; |
| 1333 // In flight packets have not been abandoned or lost. | 1331 // In flight packets have not been abandoned or lost. |
| 1334 bool in_flight; | 1332 bool in_flight; |
| 1335 // True if the packet can never be acked, so it can be removed. | 1333 // True if the packet can never be acked, so it can be removed. |
| 1336 bool is_unackable; | 1334 bool is_unackable; |
| 1337 // True if the packet is an FEC packet. | |
| 1338 bool is_fec_packet; | |
| 1339 // True if the packet contains stream data from the crypto stream. | 1335 // True if the packet contains stream data from the crypto stream. |
| 1340 bool has_crypto_handshake; | 1336 bool has_crypto_handshake; |
| 1341 // True if the packet needs padding if it's retransmitted. | 1337 // True if the packet needs padding if it's retransmitted. |
| 1342 bool needs_padding; | 1338 bool needs_padding; |
| 1343 // Stores the packet number of the next retransmission of this packet. | 1339 // Stores the packet number of the next retransmission of this packet. |
| 1344 // Zero if the packet has not been retransmitted. | 1340 // Zero if the packet has not been retransmitted. |
| 1345 QuicPacketNumber retransmission; | 1341 QuicPacketNumber retransmission; |
| 1346 // Non-empty if there is a listener for this packet. | 1342 // Non-empty if there is a listener for this packet. |
| 1347 std::list<AckListenerWrapper> ack_listeners; | 1343 std::list<AckListenerWrapper> ack_listeners; |
| 1348 }; | 1344 }; |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1385 : iov(iov), iov_count(iov_count), total_length(total_length) {} | 1381 : iov(iov), iov_count(iov_count), total_length(total_length) {} |
| 1386 | 1382 |
| 1387 const struct iovec* iov; | 1383 const struct iovec* iov; |
| 1388 const int iov_count; | 1384 const int iov_count; |
| 1389 const size_t total_length; | 1385 const size_t total_length; |
| 1390 }; | 1386 }; |
| 1391 | 1387 |
| 1392 } // namespace net | 1388 } // namespace net |
| 1393 | 1389 |
| 1394 #endif // NET_QUIC_QUIC_PROTOCOL_H_ | 1390 #endif // NET_QUIC_QUIC_PROTOCOL_H_ |
| OLD | NEW |