| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ | 5 #ifndef NET_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ |
| 6 #define NET_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ | 6 #define NET_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ |
| 7 | 7 |
| 8 #include <arpa/inet.h> // in_addr_t | 8 #include <arpa/inet.h> // in_addr_t |
| 9 #include <stddef.h> | 9 #include <stddef.h> |
| 10 #include <time.h> | 10 #include <time.h> |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 void Notify() override {} | 92 void Notify() override {} |
| 93 | 93 |
| 94 void Cleanup(const char* cleanup); | 94 void Cleanup(const char* cleanup); |
| 95 | 95 |
| 96 // Flag indicating if we should force spdy on all connections. | 96 // Flag indicating if we should force spdy on all connections. |
| 97 static bool force_spdy() { return force_spdy_; } | 97 static bool force_spdy() { return force_spdy_; } |
| 98 static void set_force_spdy(bool value) { force_spdy_ = value; } | 98 static void set_force_spdy(bool value) { force_spdy_ = value; } |
| 99 | 99 |
| 100 private: | 100 private: |
| 101 // Decide if SPDY was negotiated. | 101 // Decide if SPDY was negotiated. |
| 102 bool WasSpdyNegotiated(SpdyMajorVersion* version_negotiated); | 102 bool WasSpdyNegotiated(); |
| 103 | 103 |
| 104 // Initialize the protocol interfaces we'll need for this connection. | 104 // Initialize the protocol interfaces we'll need for this connection. |
| 105 // Returns true if successful, false otherwise. | 105 // Returns true if successful, false otherwise. |
| 106 bool SetupProtocolInterfaces(); | 106 bool SetupProtocolInterfaces(); |
| 107 | 107 |
| 108 bool DoRead(); | 108 bool DoRead(); |
| 109 bool DoWrite(); | 109 bool DoWrite(); |
| 110 bool DoConsumeReadData(); | 110 bool DoConsumeReadData(); |
| 111 void Reset(); | 111 void Reset(); |
| 112 | 112 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 154 size_t max_bytes_sent_per_dowrite_; | 154 size_t max_bytes_sent_per_dowrite_; |
| 155 | 155 |
| 156 SSL* ssl_; | 156 SSL* ssl_; |
| 157 | 157 |
| 158 static bool force_spdy_; | 158 static bool force_spdy_; |
| 159 }; | 159 }; |
| 160 | 160 |
| 161 } // namespace net | 161 } // namespace net |
| 162 | 162 |
| 163 #endif // NET_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ | 163 #endif // NET_TOOLS_FLIP_SERVER_SM_CONNECTION_H_ |
| OLD | NEW |