| 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_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 320 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 331 | 331 |
| 332 scoped_ptr<SingleRequestHostResolver> resolver_; | 332 scoped_ptr<SingleRequestHostResolver> resolver_; |
| 333 AddressList addresses_; | 333 AddressList addresses_; |
| 334 scoped_ptr<StreamSocket> socket_; | 334 scoped_ptr<StreamSocket> socket_; |
| 335 | 335 |
| 336 SSLConfig server_ssl_config_; | 336 SSLConfig server_ssl_config_; |
| 337 SSLConfig proxy_ssl_config_; | 337 SSLConfig proxy_ssl_config_; |
| 338 | 338 |
| 339 const CompletionCallback io_callback_; | 339 const CompletionCallback io_callback_; |
| 340 OldCompletionCallbackImpl<SocketStream> io_callback_old_; | 340 OldCompletionCallbackImpl<SocketStream> io_callback_old_; |
| 341 OldCompletionCallbackImpl<SocketStream> read_callback_old_; | |
| 342 OldCompletionCallbackImpl<SocketStream> write_callback_old_; | |
| 343 | 341 |
| 344 scoped_refptr<IOBuffer> read_buf_; | 342 scoped_refptr<IOBuffer> read_buf_; |
| 345 int read_buf_size_; | 343 int read_buf_size_; |
| 346 | 344 |
| 347 // Total amount of buffer (|write_buf_size_| - |write_buf_offset_| + | 345 // Total amount of buffer (|write_buf_size_| - |write_buf_offset_| + |
| 348 // sum of size of |pending_write_bufs_|) should not exceed | 346 // sum of size of |pending_write_bufs_|) should not exceed |
| 349 // |max_pending_send_allowed_|. | 347 // |max_pending_send_allowed_|. |
| 350 // |write_buf_| holds requested data and |current_write_buf_| is used | 348 // |write_buf_| holds requested data and |current_write_buf_| is used |
| 351 // for Write operation, that is, |current_write_buf_| is | 349 // for Write operation, that is, |current_write_buf_| is |
| 352 // |write_buf_| + |write_buf_offset_|. | 350 // |write_buf_| + |write_buf_offset_|. |
| 353 scoped_refptr<IOBuffer> write_buf_; | 351 scoped_refptr<IOBuffer> write_buf_; |
| 354 scoped_refptr<DrainableIOBuffer> current_write_buf_; | 352 scoped_refptr<DrainableIOBuffer> current_write_buf_; |
| 355 int write_buf_offset_; | 353 int write_buf_offset_; |
| 356 int write_buf_size_; | 354 int write_buf_size_; |
| 357 PendingDataQueue pending_write_bufs_; | 355 PendingDataQueue pending_write_bufs_; |
| 358 | 356 |
| 359 bool closing_; | 357 bool closing_; |
| 360 bool server_closed_; | 358 bool server_closed_; |
| 361 | 359 |
| 362 scoped_ptr<SocketStreamMetrics> metrics_; | 360 scoped_ptr<SocketStreamMetrics> metrics_; |
| 363 | 361 |
| 364 DISALLOW_COPY_AND_ASSIGN(SocketStream); | 362 DISALLOW_COPY_AND_ASSIGN(SocketStream); |
| 365 }; | 363 }; |
| 366 | 364 |
| 367 } // namespace net | 365 } // namespace net |
| 368 | 366 |
| 369 #endif // NET_SOCKET_STREAM_SOCKET_STREAM_H_ | 367 #endif // NET_SOCKET_STREAM_SOCKET_STREAM_H_ |
| OLD | NEW |