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

Side by Side Diff: net/quic/test_tools/quic_stream_factory_peer.cc

Issue 2417183003: Remove stl_util's deletion functions from remaining quic code. (Closed)
Patch Set: rebase Created 4 years, 2 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
« no previous file with comments | « net/quic/core/quic_unacked_packet_map_test.cc ('k') | net/quic/test_tools/quic_test_utils.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/test_tools/quic_stream_factory_peer.h" 5 #include "net/quic/test_tools/quic_stream_factory_peer.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "net/cert/x509_certificate.h" 10 #include "net/cert/x509_certificate.h"
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 115
116 void QuicStreamFactoryPeer::SetYieldAfterDuration( 116 void QuicStreamFactoryPeer::SetYieldAfterDuration(
117 QuicStreamFactory* factory, 117 QuicStreamFactory* factory,
118 QuicTime::Delta yield_after_duration) { 118 QuicTime::Delta yield_after_duration) {
119 factory->yield_after_duration_ = yield_after_duration; 119 factory->yield_after_duration_ = yield_after_duration;
120 } 120 }
121 121
122 size_t QuicStreamFactoryPeer::GetNumberOfActiveJobs( 122 size_t QuicStreamFactoryPeer::GetNumberOfActiveJobs(
123 QuicStreamFactory* factory, 123 QuicStreamFactory* factory,
124 const QuicServerId& server_id) { 124 const QuicServerId& server_id) {
125 return (factory->active_jobs_[server_id]).size(); 125 auto it = factory->active_jobs_.find(server_id);
126 if (it == factory->active_jobs_.end())
127 return 0;
128 return it->second.size();
126 } 129 }
127 130
128 void QuicStreamFactoryPeer::MaybeInitialize(QuicStreamFactory* factory) { 131 void QuicStreamFactoryPeer::MaybeInitialize(QuicStreamFactory* factory) {
129 factory->MaybeInitialize(); 132 factory->MaybeInitialize();
130 } 133 }
131 134
132 bool QuicStreamFactoryPeer::HasInitializedData(QuicStreamFactory* factory) { 135 bool QuicStreamFactoryPeer::HasInitializedData(QuicStreamFactory* factory) {
133 return factory->has_initialized_data_; 136 return factory->has_initialized_data_;
134 } 137 }
135 138
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 return &factory->push_promise_index_; 192 return &factory->push_promise_index_;
190 } 193 }
191 194
192 int QuicStreamFactoryPeer::GetNumPushStreamsCreated( 195 int QuicStreamFactoryPeer::GetNumPushStreamsCreated(
193 QuicStreamFactory* factory) { 196 QuicStreamFactory* factory) {
194 return factory->num_push_streams_created_; 197 return factory->num_push_streams_created_;
195 } 198 }
196 199
197 } // namespace test 200 } // namespace test
198 } // namespace net 201 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/core/quic_unacked_packet_map_test.cc ('k') | net/quic/test_tools/quic_test_utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698