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_REQUEST_H_ | 5 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_IMPL_REQUEST_H_ |
6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_REQUEST_H_ | 6 #define NET_HTTP_HTTP_STREAM_FACTORY_IMPL_REQUEST_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
12 #include "net/http/http_stream_factory_impl.h" | 12 #include "net/http/http_stream_factory_impl.h" |
13 #include "net/log/net_log.h" | 13 #include "net/log/net_log.h" |
| 14 #include "net/net_features.h" |
14 #include "net/socket/connection_attempts.h" | 15 #include "net/socket/connection_attempts.h" |
15 #include "net/socket/ssl_client_socket.h" | 16 #include "net/socket/ssl_client_socket.h" |
16 #include "net/spdy/spdy_session_key.h" | 17 #include "net/spdy/spdy_session_key.h" |
17 #include "net/ssl/ssl_failure_state.h" | 18 #include "net/ssl/ssl_failure_state.h" |
18 #include "url/gurl.h" | 19 #include "url/gurl.h" |
19 | 20 |
20 namespace net { | 21 namespace net { |
21 | 22 |
22 class BidirectionalStreamJob; | 23 class BidirectionalStreamJob; |
23 class ClientSocketHandle; | 24 class ClientSocketHandle; |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 // If this Request has a |spdy_session_key_|, remove this session from the | 67 // If this Request has a |spdy_session_key_|, remove this session from the |
67 // SpdySessionRequestMap. | 68 // SpdySessionRequestMap. |
68 void RemoveRequestFromSpdySessionRequestMap(); | 69 void RemoveRequestFromSpdySessionRequestMap(); |
69 | 70 |
70 // Called by an attached Job if it sets up a SpdySession. | 71 // Called by an attached Job if it sets up a SpdySession. |
71 // |stream| is null when |for_bidirectional| is true. | 72 // |stream| is null when |for_bidirectional| is true. |
72 // |bidirectional_stream_spdy_job| is null when |for_bidirectional| is false. | 73 // |bidirectional_stream_spdy_job| is null when |for_bidirectional| is false. |
73 void OnNewSpdySessionReady( | 74 void OnNewSpdySessionReady( |
74 Job* job, | 75 Job* job, |
75 scoped_ptr<HttpStream> stream, | 76 scoped_ptr<HttpStream> stream, |
76 #if defined(ENABLE_BIDIRECTIONAL_STREAM) | 77 #if BUILDFLAG(ENABLE_BIDIRECTIONAL_STREAM) |
77 scoped_ptr<BidirectionalStreamJob> bidirectional_stream_spdy_job, | 78 scoped_ptr<BidirectionalStreamJob> bidirectional_stream_spdy_job, |
78 #else | 79 #else |
79 void* unused, | 80 void* unused, |
80 #endif | 81 #endif |
81 const base::WeakPtr<SpdySession>& spdy_session, | 82 const base::WeakPtr<SpdySession>& spdy_session, |
82 bool direct); | 83 bool direct); |
83 | 84 |
84 // Called by an attached Job to record connection attempts made by the socket | 85 // Called by an attached Job to record connection attempts made by the socket |
85 // layer for this stream request. | 86 // layer for this stream request. |
86 void AddConnectionAttempts(const ConnectionAttempts& attempts); | 87 void AddConnectionAttempts(const ConnectionAttempts& attempts); |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 bool using_spdy_; | 173 bool using_spdy_; |
173 ConnectionAttempts connection_attempts_; | 174 ConnectionAttempts connection_attempts_; |
174 | 175 |
175 const bool for_bidirectional_; | 176 const bool for_bidirectional_; |
176 DISALLOW_COPY_AND_ASSIGN(Request); | 177 DISALLOW_COPY_AND_ASSIGN(Request); |
177 }; | 178 }; |
178 | 179 |
179 } // namespace net | 180 } // namespace net |
180 | 181 |
181 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_REQUEST_H_ | 182 #endif // NET_HTTP_HTTP_STREAM_FACTORY_IMPL_REQUEST_H_ |
OLD | NEW |