Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(30)

Side by Side Diff: net/quic/quic_framer.h

Issue 182523002: Land Recent QUIC Changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixed rch's comments in Patch set 1 of CL 181463007 Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/quic/quic_data_stream_test.cc ('k') | net/quic/quic_framer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_FRAMER_H_ 5 #ifndef NET_QUIC_QUIC_FRAMER_H_
6 #define NET_QUIC_QUIC_FRAMER_H_ 6 #define NET_QUIC_QUIC_FRAMER_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 const QuicFrame& frame, 282 const QuicFrame& frame,
283 size_t free_bytes, 283 size_t free_bytes,
284 bool first_frame, 284 bool first_frame,
285 bool last_frame, 285 bool last_frame,
286 QuicSequenceNumberLength sequence_number_length); 286 QuicSequenceNumberLength sequence_number_length);
287 287
288 // Returns the associated data from the encrypted packet |encrypted| as a 288 // Returns the associated data from the encrypted packet |encrypted| as a
289 // stringpiece. 289 // stringpiece.
290 static base::StringPiece GetAssociatedDataFromEncryptedPacket( 290 static base::StringPiece GetAssociatedDataFromEncryptedPacket(
291 const QuicEncryptedPacket& encrypted, 291 const QuicEncryptedPacket& encrypted,
292 QuicGuidLength guid_length, 292 QuicConnectionIdLength connection_id_length,
293 bool includes_version, 293 bool includes_version,
294 QuicSequenceNumberLength sequence_number_length); 294 QuicSequenceNumberLength sequence_number_length);
295 295
296 // Returns a SerializedPacket whose |packet| member is owned by the caller, 296 // Returns a SerializedPacket whose |packet| member is owned by the caller,
297 // and is populated with the fields in |header| and |frames|, or is NULL if 297 // and is populated with the fields in |header| and |frames|, or is NULL if
298 // the packet could not be created. 298 // the packet could not be created.
299 // TODO(ianswett): Used for testing only. 299 // TODO(ianswett): Used for testing only.
300 SerializedPacket BuildUnsizedDataPacket(const QuicPacketHeader& header, 300 SerializedPacket BuildUnsizedDataPacket(const QuicPacketHeader& header,
301 const QuicFrames& frames); 301 const QuicFrames& frames);
302 302
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
485 485
486 std::string detailed_error_; 486 std::string detailed_error_;
487 scoped_ptr<QuicDataReader> reader_; 487 scoped_ptr<QuicDataReader> reader_;
488 QuicFramerVisitorInterface* visitor_; 488 QuicFramerVisitorInterface* visitor_;
489 QuicFecBuilderInterface* fec_builder_; 489 QuicFecBuilderInterface* fec_builder_;
490 QuicReceivedEntropyHashCalculatorInterface* entropy_calculator_; 490 QuicReceivedEntropyHashCalculatorInterface* entropy_calculator_;
491 QuicErrorCode error_; 491 QuicErrorCode error_;
492 // Updated by ProcessPacketHeader when it succeeds. 492 // Updated by ProcessPacketHeader when it succeeds.
493 QuicPacketSequenceNumber last_sequence_number_; 493 QuicPacketSequenceNumber last_sequence_number_;
494 // Updated by WritePacketHeader. 494 // Updated by WritePacketHeader.
495 QuicGuid last_serialized_guid_; 495 QuicConnectionId last_serialized_connection_id_;
496 // Buffer containing decrypted payload data during parsing. 496 // Buffer containing decrypted payload data during parsing.
497 scoped_ptr<QuicData> decrypted_; 497 scoped_ptr<QuicData> decrypted_;
498 // Version of the protocol being used. 498 // Version of the protocol being used.
499 QuicVersion quic_version_; 499 QuicVersion quic_version_;
500 // This vector contains QUIC versions which we currently support. 500 // This vector contains QUIC versions which we currently support.
501 // This should be ordered such that the highest supported version is the first 501 // This should be ordered such that the highest supported version is the first
502 // element, with subsequent elements in descending order (versions can be 502 // element, with subsequent elements in descending order (versions can be
503 // skipped as necessary). 503 // skipped as necessary).
504 QuicVersionVector supported_versions_; 504 QuicVersionVector supported_versions_;
505 // Primary decrypter used to decrypt packets during parsing. 505 // Primary decrypter used to decrypt packets during parsing.
(...skipping 12 matching lines...) Expand all
518 // The time this frames was created. Time written to the wire will be 518 // The time this frames was created. Time written to the wire will be
519 // written as a delta from this value. 519 // written as a delta from this value.
520 QuicTime creation_time_; 520 QuicTime creation_time_;
521 521
522 DISALLOW_COPY_AND_ASSIGN(QuicFramer); 522 DISALLOW_COPY_AND_ASSIGN(QuicFramer);
523 }; 523 };
524 524
525 } // namespace net 525 } // namespace net
526 526
527 #endif // NET_QUIC_QUIC_FRAMER_H_ 527 #endif // NET_QUIC_QUIC_FRAMER_H_
OLDNEW
« no previous file with comments | « net/quic/quic_data_stream_test.cc ('k') | net/quic/quic_framer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698