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

Side by Side Diff: net/http/http_stream_factory_impl_request.cc

Issue 699123002: Remove HttpStreamBase. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 1 month 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
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/http/http_stream_factory_impl_request.h" 5 #include "net/http/http_stream_factory_impl_request.h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "net/http/http_stream_factory_impl_job.h" 10 #include "net/http/http_stream_factory_impl_job.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 job_net_log.source().ToEventParametersCallback()); 83 job_net_log.source().ToEventParametersCallback());
84 job_net_log.AddEvent( 84 job_net_log.AddEvent(
85 NetLog::TYPE_HTTP_STREAM_JOB_BOUND_TO_REQUEST, 85 NetLog::TYPE_HTTP_STREAM_JOB_BOUND_TO_REQUEST,
86 net_log_.source().ToEventParametersCallback()); 86 net_log_.source().ToEventParametersCallback());
87 } 87 }
88 88
89 void HttpStreamFactoryImpl::Request::OnStreamReady( 89 void HttpStreamFactoryImpl::Request::OnStreamReady(
90 Job* job, 90 Job* job,
91 const SSLConfig& used_ssl_config, 91 const SSLConfig& used_ssl_config,
92 const ProxyInfo& used_proxy_info, 92 const ProxyInfo& used_proxy_info,
93 HttpStreamBase* stream) { 93 HttpStream* stream) {
94 DCHECK(!factory_->for_websockets_); 94 DCHECK(!factory_->for_websockets_);
95 DCHECK(stream); 95 DCHECK(stream);
96 DCHECK(completed_); 96 DCHECK(completed_);
97 97
98 OnJobSucceeded(job); 98 OnJobSucceeded(job);
99 delegate_->OnStreamReady(used_ssl_config, used_proxy_info, stream); 99 delegate_->OnStreamReady(used_ssl_config, used_proxy_info, stream);
100 } 100 }
101 101
102 void HttpStreamFactoryImpl::Request::OnWebSocketHandshakeStreamReady( 102 void HttpStreamFactoryImpl::Request::OnWebSocketHandshakeStreamReady(
103 Job* job, 103 Job* job,
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 else 178 else
179 DCHECK(jobs_.empty()); 179 DCHECK(jobs_.empty());
180 delegate_->OnNeedsClientAuth(used_ssl_config, cert_info); 180 delegate_->OnNeedsClientAuth(used_ssl_config, cert_info);
181 } 181 }
182 182
183 void HttpStreamFactoryImpl::Request::OnHttpsProxyTunnelResponse( 183 void HttpStreamFactoryImpl::Request::OnHttpsProxyTunnelResponse(
184 Job *job, 184 Job *job,
185 const HttpResponseInfo& response_info, 185 const HttpResponseInfo& response_info,
186 const SSLConfig& used_ssl_config, 186 const SSLConfig& used_ssl_config,
187 const ProxyInfo& used_proxy_info, 187 const ProxyInfo& used_proxy_info,
188 HttpStreamBase* stream) { 188 HttpStream* stream) {
189 if (!bound_job_.get()) 189 if (!bound_job_.get())
190 OrphanJobsExcept(job); 190 OrphanJobsExcept(job);
191 else 191 else
192 DCHECK(jobs_.empty()); 192 DCHECK(jobs_.empty());
193 delegate_->OnHttpsProxyTunnelResponse( 193 delegate_->OnHttpsProxyTunnelResponse(
194 response_info, used_ssl_config, used_proxy_info, stream); 194 response_info, used_ssl_config, used_proxy_info, stream);
195 } 195 }
196 196
197 int HttpStreamFactoryImpl::Request::RestartTunnelWithProxyAuth( 197 int HttpStreamFactoryImpl::Request::RestartTunnelWithProxyAuth(
198 const AuthCredentials& credentials) { 198 const AuthCredentials& credentials) {
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
363 } 363 }
364 // We may have other jobs in |jobs_|. For example, if we start multiple jobs 364 // We may have other jobs in |jobs_|. For example, if we start multiple jobs
365 // for Alternate-Protocol. 365 // for Alternate-Protocol.
366 OrphanJobsExcept(job); 366 OrphanJobsExcept(job);
367 return; 367 return;
368 } 368 }
369 DCHECK(jobs_.empty()); 369 DCHECK(jobs_.empty());
370 } 370 }
371 371
372 } // namespace net 372 } // namespace net
OLDNEW
« no previous file with comments | « net/http/http_stream_factory_impl_request.h ('k') | net/http/http_stream_factory_impl_request_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698