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

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

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_session.h ('k') | net/quic/quic_stream_factory.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 #include "net/quic/quic_session.h" 5 #include "net/quic/quic_session.h"
6 6
7 #include "base/stl_util.h" 7 #include "base/stl_util.h"
8 #include "net/quic/quic_connection.h" 8 #include "net/quic/quic_connection.h"
9 9
10 using base::StringPiece; 10 using base::StringPiece;
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 // Locally created streams are strictly in-order. If the id is in the 260 // Locally created streams are strictly in-order. If the id is in the
261 // range of created streams and it's not active, it must have been closed. 261 // range of created streams and it's not active, it must have been closed.
262 return id < next_stream_id_; 262 return id < next_stream_id_;
263 } 263 }
264 // For peer created streams, we also need to consider implicitly created 264 // For peer created streams, we also need to consider implicitly created
265 // streams. 265 // streams.
266 return id <= largest_peer_created_stream_id_ && 266 return id <= largest_peer_created_stream_id_ &&
267 implicitly_created_streams_.count(id) == 0; 267 implicitly_created_streams_.count(id) == 0;
268 } 268 }
269 269
270 size_t QuicSession::GetNumOpenStreams() { 270 size_t QuicSession::GetNumOpenStreams() const {
271 return stream_map_.size() + implicitly_created_streams_.size(); 271 return stream_map_.size() + implicitly_created_streams_.size();
272 } 272 }
273 273
274 void QuicSession::MarkWriteBlocked(QuicStreamId id) { 274 void QuicSession::MarkWriteBlocked(QuicStreamId id) {
275 write_blocked_streams_.push_back(id); 275 write_blocked_streams_.push_back(id);
276 } 276 }
277 277
278 void QuicSession::PostProcessAfterData() { 278 void QuicSession::PostProcessAfterData() {
279 STLDeleteElements(&closed_streams_); 279 STLDeleteElements(&closed_streams_);
280 closed_streams_.clear(); 280 closed_streams_.clear();
281 } 281 }
282 282
283 } // namespace net 283 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_session.h ('k') | net/quic/quic_stream_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698