Chromium Code Reviews| 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_SOCKET_STREAM_SOCKET_STREAM_H_ | 5 #ifndef NET_SOCKET_STREAM_SOCKET_STREAM_H_ |
| 6 #define NET_SOCKET_STREAM_SOCKET_STREAM_H_ | 6 #define NET_SOCKET_STREAM_SOCKET_STREAM_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <deque> | 9 #include <deque> |
| 10 #include <map> | 10 #include <map> |
| (...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 258 | 258 |
| 259 enum ProxyMode { | 259 enum ProxyMode { |
| 260 kDirectConnection, // If using a direct connection | 260 kDirectConnection, // If using a direct connection |
| 261 kTunnelProxy, // If using a tunnel (CONNECT method as HTTPS) | 261 kTunnelProxy, // If using a tunnel (CONNECT method as HTTPS) |
| 262 kSOCKSProxy, // If using a SOCKS proxy | 262 kSOCKSProxy, // If using a SOCKS proxy |
| 263 }; | 263 }; |
| 264 | 264 |
| 265 // Use the same number as HttpNetworkTransaction::kMaxHeaderBufSize. | 265 // Use the same number as HttpNetworkTransaction::kMaxHeaderBufSize. |
| 266 enum { kMaxTunnelResponseHeadersSize = 32768 }; // 32 kilobytes. | 266 enum { kMaxTunnelResponseHeadersSize = 32768 }; // 32 kilobytes. |
| 267 | 267 |
| 268 // Copies the given addrinfo list in |addresses_|. | 268 // Copies |addresses| to |addresses_|. |
| 269 // Used for WebSocketThrottleTest. | 269 // Used for WebSocketThrottleTest. |
| 270 void CopyAddrInfo(struct addrinfo* head); | 270 void CopyAddressList(const AddressList& addresses); |
|
eroman
2012/05/04 01:08:41
nit: I wander if "set_addresses()" would be more a
szym
2012/05/04 02:38:29
It definitely would. Will fix.
| |
| 271 | 271 |
| 272 void DoClose(); | 272 void DoClose(); |
| 273 | 273 |
| 274 // Finishes the job. | 274 // Finishes the job. |
| 275 // Calls OnError and OnClose of delegate, and no more | 275 // Calls OnError and OnClose of delegate, and no more |
| 276 // notifications will be sent to delegate. | 276 // notifications will be sent to delegate. |
| 277 void Finish(int result); | 277 void Finish(int result); |
| 278 | 278 |
| 279 int DidEstablishSSL(int result, SSLConfig* ssl_config); | 279 int DidEstablishSSL(int result, SSLConfig* ssl_config); |
| 280 int DidEstablishConnection(); | 280 int DidEstablishConnection(); |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 378 bool server_closed_; | 378 bool server_closed_; |
| 379 | 379 |
| 380 scoped_ptr<SocketStreamMetrics> metrics_; | 380 scoped_ptr<SocketStreamMetrics> metrics_; |
| 381 | 381 |
| 382 DISALLOW_COPY_AND_ASSIGN(SocketStream); | 382 DISALLOW_COPY_AND_ASSIGN(SocketStream); |
| 383 }; | 383 }; |
| 384 | 384 |
| 385 } // namespace net | 385 } // namespace net |
| 386 | 386 |
| 387 #endif // NET_SOCKET_STREAM_SOCKET_STREAM_H_ | 387 #endif // NET_SOCKET_STREAM_SOCKET_STREAM_H_ |
| OLD | NEW |