Index: net/http/http_stream_factory_impl.h |
diff --git a/net/http/http_stream_factory_impl.h b/net/http/http_stream_factory_impl.h |
index 80e96ce8ab43d2707e5bac2d3ad8615f53a840af..6e378940f3c091912952150816d621f15aef4b89 100644 |
--- a/net/http/http_stream_factory_impl.h |
+++ b/net/http/http_stream_factory_impl.h |
@@ -15,6 +15,7 @@ |
#include "net/http/http_pipelined_host_pool.h" |
#include "net/http/http_stream_factory.h" |
#include "net/proxy/proxy_server.h" |
+#include "net/socket/client_socket_pool_manager.h" |
#include "net/socket/ssl_client_socket.h" |
#include "net/spdy/spdy_session_key.h" |
@@ -28,7 +29,9 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : |
public HttpStreamFactory, |
public HttpPipelinedHostPool::Delegate { |
public: |
- explicit HttpStreamFactoryImpl(HttpNetworkSession* session); |
+ // RequestStream may only be called if |for_websockets| is false. |
+ // RequestWebSocketStream may only be called if |for_websockets| is true. |
+ HttpStreamFactoryImpl(HttpNetworkSession* session, bool for_websockets); |
virtual ~HttpStreamFactoryImpl(); |
// HttpStreamFactory interface |
@@ -40,6 +43,15 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : |
HttpStreamRequest::Delegate* delegate, |
const BoundNetLog& net_log) OVERRIDE; |
+ virtual HttpStreamRequest* RequestWebSocketStream( |
+ const HttpRequestInfo& info, |
+ RequestPriority priority, |
+ const SSLConfig& server_ssl_config, |
+ const SSLConfig& proxy_ssl_config, |
+ HttpStreamRequest::Delegate* delegate, |
+ WebSocketStreamBase::Factory* factory, |
+ const BoundNetLog& net_log) OVERRIDE; |
+ |
virtual void PreconnectStreams(int num_streams, |
const HttpRequestInfo& info, |
RequestPriority priority, |
@@ -62,6 +74,15 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : |
typedef std::map<HttpPipelinedHost::Key, |
RequestVector> HttpPipeliningRequestMap; |
+ HttpStreamRequest* RequestStreamInternal( |
+ const HttpRequestInfo& info, |
+ RequestPriority priority, |
+ const SSLConfig& server_ssl_config, |
+ const SSLConfig& proxy_ssl_config, |
+ HttpStreamRequest::Delegate* delegate, |
+ WebSocketStreamBase::Factory* factory, |
+ const BoundNetLog& net_log); |
+ |
PortAlternateProtocolPair GetAlternateProtocolRequestFor( |
const GURL& original_url, |
GURL* alternate_url) const; |
@@ -72,14 +93,14 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : |
// Called when a SpdySession is ready. It will find appropriate Requests and |
// fulfill them. |direct| indicates whether or not |spdy_session| uses a |
// proxy. |
- void OnSpdySessionReady(scoped_refptr<SpdySession> spdy_session, |
- bool direct, |
- const SSLConfig& used_ssl_config, |
- const ProxyInfo& used_proxy_info, |
- bool was_npn_negotiated, |
- NextProto protocol_negotiated, |
- bool using_spdy, |
- const BoundNetLog& net_log); |
+ void OnNewSpdySessionReady(scoped_refptr<SpdySession> spdy_session, |
+ bool direct, |
+ const SSLConfig& used_ssl_config, |
+ const ProxyInfo& used_proxy_info, |
+ bool was_npn_negotiated, |
+ NextProto protocol_negotiated, |
+ bool using_spdy, |
+ const BoundNetLog& net_log); |
// Called when the Job detects that the endpoint indicated by the |
// Alternate-Protocol does not work. Lets the factory update |
@@ -124,6 +145,7 @@ class NET_EXPORT_PRIVATE HttpStreamFactoryImpl : |
// deleted when the factory is destroyed. |
std::set<const Job*> preconnect_job_set_; |
+ const bool for_websockets_; |
mmenke
2013/06/03 21:10:18
I may have been wrong to suggest this - it's fine
|
DISALLOW_COPY_AND_ASSIGN(HttpStreamFactoryImpl); |
}; |