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 #include "net/socket/client_socket_pool_base.h" | 5 #include "net/socket/client_socket_pool_base.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 IOBuffer* /* buf */, int len, const CompletionCallback& /* callback */) { | 71 IOBuffer* /* buf */, int len, const CompletionCallback& /* callback */) { |
72 num_bytes_read_ += len; | 72 num_bytes_read_ += len; |
73 return len; | 73 return len; |
74 } | 74 } |
75 | 75 |
76 virtual int Write( | 76 virtual int Write( |
77 IOBuffer* /* buf */, int len, OldCompletionCallback* /* callback */) { | 77 IOBuffer* /* buf */, int len, OldCompletionCallback* /* callback */) { |
78 was_used_to_convey_data_ = true; | 78 was_used_to_convey_data_ = true; |
79 return len; | 79 return len; |
80 } | 80 } |
| 81 virtual int Write( |
| 82 IOBuffer* /* buf */, int len, const CompletionCallback& /* callback */) { |
| 83 was_used_to_convey_data_ = true; |
| 84 return len; |
| 85 } |
81 virtual bool SetReceiveBufferSize(int32 size) { return true; } | 86 virtual bool SetReceiveBufferSize(int32 size) { return true; } |
82 virtual bool SetSendBufferSize(int32 size) { return true; } | 87 virtual bool SetSendBufferSize(int32 size) { return true; } |
83 | 88 |
84 // StreamSocket implementation. | 89 // StreamSocket implementation. |
85 virtual int Connect(OldCompletionCallback* callback) { | 90 virtual int Connect(OldCompletionCallback* callback) { |
86 connected_ = true; | 91 connected_ = true; |
87 return OK; | 92 return OK; |
88 } | 93 } |
89 virtual int Connect(const net::CompletionCallback& callback) { | 94 virtual int Connect(const net::CompletionCallback& callback) { |
90 connected_ = true; | 95 connected_ = true; |
(...skipping 3413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3504 params_, | 3509 params_, |
3505 kDefaultPriority, | 3510 kDefaultPriority, |
3506 &callback, | 3511 &callback, |
3507 pool_.get(), | 3512 pool_.get(), |
3508 BoundNetLog())); | 3513 BoundNetLog())); |
3509 } | 3514 } |
3510 | 3515 |
3511 } // namespace | 3516 } // namespace |
3512 | 3517 |
3513 } // namespace net | 3518 } // namespace net |
OLD | NEW |