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

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

Issue 312553003: Land Recent QUIC Changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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_packet_generator_test.cc ('k') | net/quic/quic_protocol.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_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 <limits> 9 #include <limits>
10 #include <map> 10 #include <map>
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 // representation of the name of the tag. For example 311 // representation of the name of the tag. For example
312 // the client hello tag (CHLO) will be written as the 312 // the client hello tag (CHLO) will be written as the
313 // following 4 bytes: 'C' 'H' 'L' 'O'. Since it is 313 // following 4 bytes: 'C' 'H' 'L' 'O'. Since it is
314 // stored in memory as a little endian uint32, we need 314 // stored in memory as a little endian uint32, we need
315 // to reverse the order of the bytes. 315 // to reverse the order of the bytes.
316 316
317 // MakeQuicTag returns a value given the four bytes. For example: 317 // MakeQuicTag returns a value given the four bytes. For example:
318 // MakeQuicTag('C', 'H', 'L', 'O'); 318 // MakeQuicTag('C', 'H', 'L', 'O');
319 NET_EXPORT_PRIVATE QuicTag MakeQuicTag(char a, char b, char c, char d); 319 NET_EXPORT_PRIVATE QuicTag MakeQuicTag(char a, char b, char c, char d);
320 320
321 // Returns true if the tag vector contains the specified tag.
322 bool ContainsQuicTag(QuicTagVector tag_vector, QuicTag tag);
323
321 // Size in bytes of the data or fec packet header. 324 // Size in bytes of the data or fec packet header.
322 NET_EXPORT_PRIVATE size_t GetPacketHeaderSize(const QuicPacketHeader& header); 325 NET_EXPORT_PRIVATE size_t GetPacketHeaderSize(const QuicPacketHeader& header);
323 326
324 NET_EXPORT_PRIVATE size_t GetPacketHeaderSize( 327 NET_EXPORT_PRIVATE size_t GetPacketHeaderSize(
325 QuicConnectionIdLength connection_id_length, 328 QuicConnectionIdLength connection_id_length,
326 bool include_version, 329 bool include_version,
327 QuicSequenceNumberLength sequence_number_length, 330 QuicSequenceNumberLength sequence_number_length,
328 InFecGroup is_in_fec_group); 331 InFecGroup is_in_fec_group);
329 332
330 // Index of the first byte in a QUIC packet of FEC protected data. 333 // Index of the first byte in a QUIC packet of FEC protected data.
(...skipping 745 matching lines...) Expand 10 before | Expand all | Expand 10 after
1076 WriteStatus status; 1079 WriteStatus status;
1077 union { 1080 union {
1078 int bytes_written; // only valid when status is OK 1081 int bytes_written; // only valid when status is OK
1079 int error_code; // only valid when status is ERROR 1082 int error_code; // only valid when status is ERROR
1080 }; 1083 };
1081 }; 1084 };
1082 1085
1083 } // namespace net 1086 } // namespace net
1084 1087
1085 #endif // NET_QUIC_QUIC_PROTOCOL_H_ 1088 #endif // NET_QUIC_QUIC_PROTOCOL_H_
OLDNEW
« no previous file with comments | « net/quic/quic_packet_generator_test.cc ('k') | net/quic/quic_protocol.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698