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

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

Issue 112273003: Add a version() convenience method to ReliableQuicStream. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 | « no previous file | net/quic/reliable_quic_stream.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 // The base class for client/server reliable streams. 5 // The base class for client/server reliable streams.
6 6
7 #ifndef NET_QUIC_RELIABLE_QUIC_STREAM_H_ 7 #ifndef NET_QUIC_RELIABLE_QUIC_STREAM_H_
8 #define NET_QUIC_RELIABLE_QUIC_STREAM_H_ 8 #define NET_QUIC_RELIABLE_QUIC_STREAM_H_
9 9
10 #include <sys/types.h> 10 #include <sys/types.h>
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 79
80 QuicRstStreamErrorCode stream_error() const { return stream_error_; } 80 QuicRstStreamErrorCode stream_error() const { return stream_error_; }
81 QuicErrorCode connection_error() const { return connection_error_; } 81 QuicErrorCode connection_error() const { return connection_error_; }
82 82
83 bool read_side_closed() const { return read_side_closed_; } 83 bool read_side_closed() const { return read_side_closed_; }
84 bool write_side_closed() const { return write_side_closed_; } 84 bool write_side_closed() const { return write_side_closed_; }
85 85
86 uint64 stream_bytes_read() { return stream_bytes_read_; } 86 uint64 stream_bytes_read() { return stream_bytes_read_; }
87 uint64 stream_bytes_written() { return stream_bytes_written_; } 87 uint64 stream_bytes_written() { return stream_bytes_written_; }
88 88
89 QuicVersion version();
90
89 protected: 91 protected:
90 // Sends as much of 'data' to the connection as the connection will consume, 92 // Sends as much of 'data' to the connection as the connection will consume,
91 // and then buffers any remaining data in queued_data_. 93 // and then buffers any remaining data in queued_data_.
92 void WriteOrBufferData(base::StringPiece data, bool fin); 94 void WriteOrBufferData(base::StringPiece data, bool fin);
93 95
94 // Sends as many bytes in the first |count| buffers of |iov| to the connection 96 // Sends as many bytes in the first |count| buffers of |iov| to the connection
95 // as the connection will consume. 97 // as the connection will consume.
96 // If |ack_notifier_delegate| is provided, then it will be notified once all 98 // If |ack_notifier_delegate| is provided, then it will be notified once all
97 // the ACKs for this write have been received. 99 // the ACKs for this write have been received.
98 // Returns the number of bytes consumed by the connection. 100 // Returns the number of bytes consumed by the connection.
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 151
150 // True if the session this stream is running under is a server session. 152 // True if the session this stream is running under is a server session.
151 bool is_server_; 153 bool is_server_;
152 154
153 DISALLOW_COPY_AND_ASSIGN(ReliableQuicStream); 155 DISALLOW_COPY_AND_ASSIGN(ReliableQuicStream);
154 }; 156 };
155 157
156 } // namespace net 158 } // namespace net
157 159
158 #endif // NET_QUIC_RELIABLE_QUIC_STREAM_H_ 160 #endif // NET_QUIC_RELIABLE_QUIC_STREAM_H_
OLDNEW
« no previous file with comments | « no previous file | net/quic/reliable_quic_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698