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

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

Issue 1905843003: Split out QuicAlarm creation from QuicConnectionHelper to new QuicAlarmFactory. No behavior change,… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@119753783
Patch Set: Rebase Created 4 years, 8 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/tools/quic/quic_client_base.h ('k') | net/tools/quic/quic_client_session_test.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) 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 #include "net/tools/quic/quic_client_base.h" 5 #include "net/tools/quic/quic_client_base.h"
6 6
7 #include "net/quic/crypto/quic_random.h" 7 #include "net/quic/crypto/quic_random.h"
8 #include "net/quic/quic_server_id.h" 8 #include "net/quic/quic_server_id.h"
9 9
10 namespace net { 10 namespace net {
11 11
12 QuicClientBase::QuicClientBase(const QuicServerId& server_id, 12 QuicClientBase::QuicClientBase(const QuicServerId& server_id,
13 const QuicVersionVector& supported_versions, 13 const QuicVersionVector& supported_versions,
14 const QuicConfig& config, 14 const QuicConfig& config,
15 QuicConnectionHelperInterface* helper, 15 QuicConnectionHelperInterface* helper,
16 QuicAlarmFactory* alarm_factory,
16 ProofVerifier* proof_verifier) 17 ProofVerifier* proof_verifier)
17 : server_id_(server_id), 18 : server_id_(server_id),
18 config_(config), 19 config_(config),
19 crypto_config_(proof_verifier), 20 crypto_config_(proof_verifier),
20 helper_(helper), 21 helper_(helper),
22 alarm_factory_(alarm_factory),
21 supported_versions_(supported_versions), 23 supported_versions_(supported_versions),
22 initial_max_packet_length_(0), 24 initial_max_packet_length_(0),
23 num_stateless_rejects_received_(0), 25 num_stateless_rejects_received_(0),
24 num_sent_client_hellos_(0), 26 num_sent_client_hellos_(0),
25 connection_error_(QUIC_NO_ERROR), 27 connection_error_(QUIC_NO_ERROR),
26 connected_or_attempting_connect_(false) {} 28 connected_or_attempting_connect_(false) {}
27 29
28 QuicClientBase::~QuicClientBase() {} 30 QuicClientBase::~QuicClientBase() {}
29 31
30 bool QuicClientBase::Initialize() { 32 bool QuicClientBase::Initialize() {
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 return cached->has_server_designated_connection_id() 144 return cached->has_server_designated_connection_id()
143 ? cached->GetNextServerDesignatedConnectionId() 145 ? cached->GetNextServerDesignatedConnectionId()
144 : 0; 146 : 0;
145 } 147 }
146 148
147 QuicConnectionId QuicClientBase::GenerateNewConnectionId() { 149 QuicConnectionId QuicClientBase::GenerateNewConnectionId() {
148 return QuicRandom::GetInstance()->RandUint64(); 150 return QuicRandom::GetInstance()->RandUint64();
149 } 151 }
150 152
151 } // namespace net 153 } // namespace net
OLDNEW
« no previous file with comments | « net/tools/quic/quic_client_base.h ('k') | net/tools/quic/quic_client_session_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698