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_H_ | 5 #ifndef NET_HTTP_HTTP_STREAM_FACTORY_H_ |
6 #define NET_HTTP_HTTP_STREAM_FACTORY_H_ | 6 #define NET_HTTP_HTTP_STREAM_FACTORY_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
223 static void set_force_spdy_always(bool value) { | 223 static void set_force_spdy_always(bool value) { |
224 force_spdy_always_ = value; | 224 force_spdy_always_ = value; |
225 } | 225 } |
226 static bool force_spdy_always() { return force_spdy_always_; } | 226 static bool force_spdy_always() { return force_spdy_always_; } |
227 | 227 |
228 // Add a URL to exclude from forced SPDY. | 228 // Add a URL to exclude from forced SPDY. |
229 static void add_forced_spdy_exclusion(const std::string& value); | 229 static void add_forced_spdy_exclusion(const std::string& value); |
230 // Check if a HostPortPair is excluded from using spdy. | 230 // Check if a HostPortPair is excluded from using spdy. |
231 static bool HasSpdyExclusion(const HostPortPair& endpoint); | 231 static bool HasSpdyExclusion(const HostPortPair& endpoint); |
232 | 232 |
| 233 // Sets http/1.1, spdy/2, spdy/2.1 and spdy/3 as the protocols supported. |
| 234 static void EnableSPDY3(); |
| 235 |
| 236 // Sets http/1.1, spdy/2 and spdy/2.1 as the protocols supported. |
| 237 // If flow-control is enabled, received WINDOW_UPDATE and SETTINGS messages |
| 238 // are processed and outstanding window size is actually obeyed when sending |
| 239 // data frames, and WINDOW_UPDATE messages are generated when data is |
| 240 // consumed. |
| 241 static void EnableFlowControl(); |
| 242 |
233 // Sets the protocols supported by NPN (next protocol negotiation) during the | 243 // Sets the protocols supported by NPN (next protocol negotiation) during the |
234 // SSL handshake as well as by HTTP Alternate-Protocol. | 244 // SSL handshake as well as by HTTP Alternate-Protocol. |
235 static void SetNextProtos(const std::vector<std::string>& value); | 245 static void SetNextProtos(const std::vector<std::string>& value); |
236 static bool has_next_protos() { return next_protos_ != NULL; } | 246 static bool has_next_protos() { return next_protos_ != NULL; } |
237 static const std::vector<std::string>& next_protos() { | 247 static const std::vector<std::string>& next_protos() { |
238 return *next_protos_; | 248 return *next_protos_; |
239 } | 249 } |
240 | 250 |
241 // Sets the HttpStreamFactoryImpl into a mode where it can ignore certificate | 251 // Sets the HttpStreamFactoryImpl into a mode where it can ignore certificate |
242 // errors. This is for testing. | 252 // errors. This is for testing. |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
282 static bool http_pipelining_enabled_; | 292 static bool http_pipelining_enabled_; |
283 static uint16 testing_fixed_http_port_; | 293 static uint16 testing_fixed_http_port_; |
284 static uint16 testing_fixed_https_port_; | 294 static uint16 testing_fixed_https_port_; |
285 | 295 |
286 DISALLOW_COPY_AND_ASSIGN(HttpStreamFactory); | 296 DISALLOW_COPY_AND_ASSIGN(HttpStreamFactory); |
287 }; | 297 }; |
288 | 298 |
289 } // namespace net | 299 } // namespace net |
290 | 300 |
291 #endif // NET_HTTP_HTTP_STREAM_FACTORY_H_ | 301 #endif // NET_HTTP_HTTP_STREAM_FACTORY_H_ |
OLD | NEW |