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

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

Issue 763833003: Remove using namespace in net/quic/quic_stream_sequencer.h (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix missing part device_cloud_policy_manager_chromeos_unittest.cc Created 6 years 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.h ('k') | net/tools/quic/quic_dispatcher_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) 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 toy client, which connects to a specified port and sends QUIC 5 // A toy client, which connects to a specified port and sends QUIC
6 // request to that endpoint. 6 // request to that endpoint.
7 7
8 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_H_ 8 #ifndef NET_TOOLS_QUIC_QUIC_CLIENT_H_
9 #define NET_TOOLS_QUIC_QUIC_CLIENT_H_ 9 #define NET_TOOLS_QUIC_QUIC_CLIENT_H_
10 10
(...skipping 26 matching lines...) Expand all
37 37
38 class QuicClient : public EpollCallbackInterface, 38 class QuicClient : public EpollCallbackInterface,
39 public QuicDataStream::Visitor { 39 public QuicDataStream::Visitor {
40 public: 40 public:
41 class ResponseListener { 41 class ResponseListener {
42 public: 42 public:
43 ResponseListener() {} 43 ResponseListener() {}
44 virtual ~ResponseListener() {} 44 virtual ~ResponseListener() {}
45 virtual void OnCompleteResponse(QuicStreamId id, 45 virtual void OnCompleteResponse(QuicStreamId id,
46 const BalsaHeaders& response_headers, 46 const BalsaHeaders& response_headers,
47 const string& response_body) = 0; 47 const std::string& response_body) = 0;
48 }; 48 };
49 49
50 // Create a quic client, which will have events managed by an externally owned 50 // Create a quic client, which will have events managed by an externally owned
51 // EpollServer. 51 // EpollServer.
52 QuicClient(IPEndPoint server_address, 52 QuicClient(IPEndPoint server_address,
53 const QuicServerId& server_id, 53 const QuicServerId& server_id,
54 const QuicVersionVector& supported_versions, 54 const QuicVersionVector& supported_versions,
55 bool print_response, 55 bool print_response,
56 EpollServer* epoll_server); 56 EpollServer* epoll_server);
57 QuicClient(IPEndPoint server_address, 57 QuicClient(IPEndPoint server_address,
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 136
137 int fd() { return fd_; } 137 int fd() { return fd_; }
138 138
139 const QuicServerId& server_id() const { return server_id_; } 139 const QuicServerId& server_id() const { return server_id_; }
140 140
141 // This should only be set before the initial Connect() 141 // This should only be set before the initial Connect()
142 void set_server_id(const QuicServerId& server_id) { 142 void set_server_id(const QuicServerId& server_id) {
143 server_id_ = server_id; 143 server_id_ = server_id;
144 } 144 }
145 145
146 void SetUserAgentID(const string& user_agent_id) { 146 void SetUserAgentID(const std::string& user_agent_id) {
147 crypto_config_.set_user_agent_id(user_agent_id); 147 crypto_config_.set_user_agent_id(user_agent_id);
148 } 148 }
149 149
150 // SetProofVerifier sets the ProofVerifier that will be used to verify the 150 // SetProofVerifier sets the ProofVerifier that will be used to verify the
151 // server's certificate and takes ownership of |verifier|. 151 // server's certificate and takes ownership of |verifier|.
152 void SetProofVerifier(ProofVerifier* verifier) { 152 void SetProofVerifier(ProofVerifier* verifier) {
153 // TODO(rtenneti): We should set ProofVerifier in QuicClientSession. 153 // TODO(rtenneti): We should set ProofVerifier in QuicClientSession.
154 crypto_config_.SetProofVerifier(verifier); 154 crypto_config_.SetProofVerifier(verifier);
155 } 155 }
156 156
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 // when the stream is closed (in OnClose). 265 // when the stream is closed (in OnClose).
266 bool print_response_; 266 bool print_response_;
267 267
268 DISALLOW_COPY_AND_ASSIGN(QuicClient); 268 DISALLOW_COPY_AND_ASSIGN(QuicClient);
269 }; 269 };
270 270
271 } // namespace tools 271 } // namespace tools
272 } // namespace net 272 } // namespace net
273 273
274 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_H_ 274 #endif // NET_TOOLS_QUIC_QUIC_CLIENT_H_
OLDNEW
« no previous file with comments | « net/quic/test_tools/quic_test_utils.h ('k') | net/tools/quic/quic_dispatcher_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698