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

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

Issue 12806002: Land Recent QUIC Changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: minor comment fix Created 7 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_crypto_stream_test.cc ('k') | net/quic/quic_framer.h » ('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_DATA_READER_H_ 5 #ifndef NET_QUIC_QUIC_DATA_READER_H_
6 #define NET_QUIC_QUIC_DATA_READER_H_ 6 #define NET_QUIC_QUIC_DATA_READER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/string_piece.h" 9 #include "base/string_piece.h"
10 #include "net/base/int128.h" 10 #include "net/base/int128.h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 // Reads a 64-bit unsigned integer into the given output parameter. 52 // Reads a 64-bit unsigned integer into the given output parameter.
53 // Forwards the internal iterator on success. 53 // Forwards the internal iterator on success.
54 // Returns true on success, false otherwise. 54 // Returns true on success, false otherwise.
55 bool ReadUInt64(uint64* result); 55 bool ReadUInt64(uint64* result);
56 56
57 // Reads a 128-bit unsigned integer into the given output parameter. 57 // Reads a 128-bit unsigned integer into the given output parameter.
58 // Forwards the internal iterator on success. 58 // Forwards the internal iterator on success.
59 // Returns true on success, false otherwise. 59 // Returns true on success, false otherwise.
60 bool ReadUInt128(uint128* result); 60 bool ReadUInt128(uint128* result);
61
61 // Reads a string prefixed with 16-bit length into the given output parameter. 62 // Reads a string prefixed with 16-bit length into the given output parameter.
62 // 63 //
63 // NOTE: Does not copy but rather references strings in the underlying buffer. 64 // NOTE: Does not copy but rather references strings in the underlying buffer.
64 // This should be kept in mind when handling memory management! 65 // This should be kept in mind when handling memory management!
65 // 66 //
66 // Forwards the internal iterator on success. 67 // Forwards the internal iterator on success.
67 // Returns true on success, false otherwise. 68 // Returns true on success, false otherwise.
68 bool ReadStringPiece16(base::StringPiece* result); 69 bool ReadStringPiece16(base::StringPiece* result);
69 70
70 // Reads a given number of bytes into the given buffer. The buffer 71 // Reads a given number of bytes into the given buffer. The buffer
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 // The length of the data buffer that we're reading from. 117 // The length of the data buffer that we're reading from.
117 const size_t len_; 118 const size_t len_;
118 119
119 // The location of the next read from our data buffer. 120 // The location of the next read from our data buffer.
120 size_t pos_; 121 size_t pos_;
121 }; 122 };
122 123
123 } // namespace net 124 } // namespace net
124 125
125 #endif // NET_QUIC_QUIC_DATA_READER_H_ 126 #endif // NET_QUIC_QUIC_DATA_READER_H_
OLDNEW
« no previous file with comments | « net/quic/quic_crypto_stream_test.cc ('k') | net/quic/quic_framer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698