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

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

Issue 11696010: Integrate QUIC info into net-internals. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tests Created 7 years, 11 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_client_session.cc ('k') | net/quic/quic_session.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 // A QuicSession, which demuxes a single connection to individual streams. 5 // A QuicSession, which demuxes a single connection to individual streams.
6 6
7 #ifndef NET_QUIC_QUIC_SESSION_H_ 7 #ifndef NET_QUIC_QUIC_SESSION_H_
8 #define NET_QUIC_QUIC_SESSION_H_ 8 #define NET_QUIC_QUIC_SESSION_H_
9 9
10 #include <vector> 10 #include <vector>
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 // Returns true if the stream existed previously and has been closed. 69 // Returns true if the stream existed previously and has been closed.
70 // Returns false if the stream is still active or if the stream has 70 // Returns false if the stream is still active or if the stream has
71 // not yet been created. 71 // not yet been created.
72 bool IsClosedStream(QuicStreamId id); 72 bool IsClosedStream(QuicStreamId id);
73 73
74 QuicConnection* connection() { return connection_.get(); } 74 QuicConnection* connection() { return connection_.get(); }
75 size_t num_active_requests() const { return stream_map_.size(); } 75 size_t num_active_requests() const { return stream_map_.size(); }
76 const IPEndPoint& peer_address() const { 76 const IPEndPoint& peer_address() const {
77 return connection_->peer_address(); 77 return connection_->peer_address();
78 } 78 }
79 QuicGuid guid() const { return connection_->guid(); }
79 80
80 QuicPacketCreator::Options* options() { return connection()->options(); } 81 QuicPacketCreator::Options* options() { return connection()->options(); }
81 82
82 // Returns the number of currently open streams, including those which have 83 // Returns the number of currently open streams, including those which have
83 // been implicitly created. 84 // been implicitly created.
84 virtual size_t GetNumOpenStreams(); 85 virtual size_t GetNumOpenStreams() const;
85 86
86 void MarkWriteBlocked(QuicStreamId id); 87 void MarkWriteBlocked(QuicStreamId id);
87 88
88 protected: 89 protected:
89 // Creates a new stream, owned by the caller, to handle a peer-initiated 90 // Creates a new stream, owned by the caller, to handle a peer-initiated
90 // stream. Returns NULL and does error handling if the stream can not be 91 // stream. Returns NULL and does error handling if the stream can not be
91 // created. 92 // created.
92 virtual ReliableQuicStream* CreateIncomingReliableStream(QuicStreamId id) = 0; 93 virtual ReliableQuicStream* CreateIncomingReliableStream(QuicStreamId id) = 0;
93 94
94 // Create a new stream, owned by the caller, to handle a locally-initiated 95 // Create a new stream, owned by the caller, to handle a locally-initiated
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 155
155 // A list of streams which need to write more data. 156 // A list of streams which need to write more data.
156 std::list<QuicStreamId> write_blocked_streams_; 157 std::list<QuicStreamId> write_blocked_streams_;
157 158
158 QuicStreamId largest_peer_created_stream_id_; 159 QuicStreamId largest_peer_created_stream_id_;
159 }; 160 };
160 161
161 } // namespace net 162 } // namespace net
162 163
163 #endif // NET_QUIC_QUIC_SESSION_H_ 164 #endif // NET_QUIC_QUIC_SESSION_H_
OLDNEW
« no previous file with comments | « net/quic/quic_client_session.cc ('k') | net/quic/quic_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698