OLD | NEW |
---|---|
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 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 5 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
7 | 7 |
8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
119 STATE_RESTART_TUNNEL_AUTH_COMPLETE, | 119 STATE_RESTART_TUNNEL_AUTH_COMPLETE, |
120 STATE_CREATE_STREAM, | 120 STATE_CREATE_STREAM, |
121 STATE_CREATE_STREAM_COMPLETE, | 121 STATE_CREATE_STREAM_COMPLETE, |
122 STATE_DRAIN_BODY_FOR_AUTH_RESTART, | 122 STATE_DRAIN_BODY_FOR_AUTH_RESTART, |
123 STATE_DRAIN_BODY_FOR_AUTH_RESTART_COMPLETE, | 123 STATE_DRAIN_BODY_FOR_AUTH_RESTART_COMPLETE, |
124 STATE_DONE, | 124 STATE_DONE, |
125 STATE_NONE | 125 STATE_NONE |
126 }; | 126 }; |
127 | 127 |
128 void OnStreamReadyCallback(); | 128 void OnStreamReadyCallback(); |
129 void OnSpdySessionReadyForWSCallback(); | |
130 void OnSocketReadyCallback(); | |
mmenke
2013/05/15 15:38:20
nit: You have the socket function first everywher
yhirano
2013/05/16 05:02:35
Done.
| |
129 void OnSpdySessionReadyCallback(); | 131 void OnSpdySessionReadyCallback(); |
130 void OnStreamFailedCallback(int result); | 132 void OnStreamFailedCallback(int result); |
131 void OnCertificateErrorCallback(int result, const SSLInfo& ssl_info); | 133 void OnCertificateErrorCallback(int result, const SSLInfo& ssl_info); |
132 void OnNeedsProxyAuthCallback(const HttpResponseInfo& response_info, | 134 void OnNeedsProxyAuthCallback(const HttpResponseInfo& response_info, |
133 HttpAuthController* auth_controller); | 135 HttpAuthController* auth_controller); |
134 void OnNeedsClientAuthCallback(SSLCertRequestInfo* cert_info); | 136 void OnNeedsClientAuthCallback(SSLCertRequestInfo* cert_info); |
135 void OnHttpsProxyTunnelResponseCallback(const HttpResponseInfo& response_info, | 137 void OnHttpsProxyTunnelResponseCallback(const HttpResponseInfo& response_info, |
136 HttpStream* stream); | 138 HttpStream* stream); |
137 void OnPreconnectsComplete(); | 139 void OnPreconnectsComplete(); |
138 | 140 |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
301 // 0 if we're not preconnecting. Otherwise, the number of streams to | 303 // 0 if we're not preconnecting. Otherwise, the number of streams to |
302 // preconnect. | 304 // preconnect. |
303 int num_streams_; | 305 int num_streams_; |
304 | 306 |
305 // Initialized when we create a new SpdySession. | 307 // Initialized when we create a new SpdySession. |
306 scoped_refptr<SpdySession> new_spdy_session_; | 308 scoped_refptr<SpdySession> new_spdy_session_; |
307 | 309 |
308 // Initialized when we have an existing SpdySession. | 310 // Initialized when we have an existing SpdySession. |
309 scoped_refptr<SpdySession> existing_spdy_session_; | 311 scoped_refptr<SpdySession> existing_spdy_session_; |
310 | 312 |
313 // A SPDY session to pass to OnSpdySessionReadyForWSCallback | |
314 scoped_refptr<SpdySession> spdy_session_to_pass_; | |
315 | |
311 // Only used if |new_spdy_session_| is non-NULL. | 316 // Only used if |new_spdy_session_| is non-NULL. |
312 bool spdy_session_direct_; | 317 bool spdy_session_direct_; |
313 | 318 |
314 // Key used to identify the HttpPipelinedHost for |request_|. | 319 // Key used to identify the HttpPipelinedHost for |request_|. |
315 scoped_ptr<HttpPipelinedHost::Key> http_pipelining_key_; | 320 scoped_ptr<HttpPipelinedHost::Key> http_pipelining_key_; |
316 | 321 |
317 // True if an existing pipeline can handle this job's request. | 322 // True if an existing pipeline can handle this job's request. |
318 bool existing_available_pipeline_; | 323 bool existing_available_pipeline_; |
319 | 324 |
320 base::WeakPtrFactory<Job> ptr_factory_; | 325 base::WeakPtrFactory<Job> ptr_factory_; |
321 | 326 |
322 DISALLOW_COPY_AND_ASSIGN(Job); | 327 DISALLOW_COPY_AND_ASSIGN(Job); |
323 }; | 328 }; |
324 | 329 |
325 } // namespace net | 330 } // namespace net |
326 | 331 |
327 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ | 332 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_JOB_H_ |
OLD | NEW |