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

Side by Side Diff: net/tools/quic/quic_client_base.h

Issue 2226643004: QuicSession no longer directly owns its QuicConnection. Not flag protected. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@129226757
Patch Set: Created 4 years, 4 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/test_tools/quic_test_utils.cc ('k') | net/tools/quic/quic_client_session.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) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 // A base class for the toy client, which connects to a specified port and sends 5 // A base class for the toy client, which connects to a specified port and sends
6 // QUIC request to that endpoint. 6 // QUIC request to that endpoint.
7 7
8 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_ 8 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_
9 #define NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_ 9 #define NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_
10 10
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 158
159 ProofVerifier* proof_verifier() const; 159 ProofVerifier* proof_verifier() const;
160 160
161 void set_session(QuicClientSession* session) { session_.reset(session); } 161 void set_session(QuicClientSession* session) { session_.reset(session); }
162 162
163 QuicClientPushPromiseIndex* push_promise_index() { 163 QuicClientPushPromiseIndex* push_promise_index() {
164 return &push_promise_index_; 164 return &push_promise_index_;
165 } 165 }
166 166
167 protected: 167 protected:
168 // Takes ownership of |connection|.
168 virtual QuicClientSession* CreateQuicClientSession( 169 virtual QuicClientSession* CreateQuicClientSession(
169 QuicConnection* connection); 170 QuicConnection* connection);
170 171
171 // Generates the next ConnectionId for |server_id_|. By default, if the 172 // Generates the next ConnectionId for |server_id_|. By default, if the
172 // cached server config contains a server-designated ID, that ID will be 173 // cached server config contains a server-designated ID, that ID will be
173 // returned. Otherwise, the next random ID will be returned. 174 // returned. Otherwise, the next random ID will be returned.
174 QuicConnectionId GetNextConnectionId(); 175 QuicConnectionId GetNextConnectionId();
175 176
176 // Returns the next server-designated ConnectionId from the cached config for 177 // Returns the next server-designated ConnectionId from the cached config for
177 // |server_id_|, if it exists. Otherwise, returns 0. 178 // |server_id_|, if it exists. Otherwise, returns 0.
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 bool connected_or_attempting_connect_; 249 bool connected_or_attempting_connect_;
249 250
250 QuicClientPushPromiseIndex push_promise_index_; 251 QuicClientPushPromiseIndex push_promise_index_;
251 252
252 DISALLOW_COPY_AND_ASSIGN(QuicClientBase); 253 DISALLOW_COPY_AND_ASSIGN(QuicClientBase);
253 }; 254 };
254 255
255 } // namespace net 256 } // namespace net
256 257
257 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_ 258 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_BASE_H_
OLDNEW
« no previous file with comments | « net/quic/test_tools/quic_test_utils.cc ('k') | net/tools/quic/quic_client_session.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698