Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(83)

Side by Side Diff: net/socket/stream_socket.h

Issue 8801004: base::Bind: Convert StreamSocket::Connect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review fixes Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « net/socket/ssl_server_socket_unittest.cc ('k') | net/socket/tcp_client_socket_libevent.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_H_ 5 #ifndef NET_SOCKET_STREAM_SOCKET_H_
6 #define NET_SOCKET_STREAM_SOCKET_H_ 6 #define NET_SOCKET_STREAM_SOCKET_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "net/base/net_log.h" 10 #include "net/base/net_log.h"
(...skipping 16 matching lines...) Expand all
27 // 27 //
28 // The socket's Read and Write methods may not be called until Connect 28 // The socket's Read and Write methods may not be called until Connect
29 // succeeds. 29 // succeeds.
30 // 30 //
31 // It is valid to call Connect on an already connected socket, in which case 31 // It is valid to call Connect on an already connected socket, in which case
32 // OK is simply returned. 32 // OK is simply returned.
33 // 33 //
34 // Connect may also be called again after a call to the Disconnect method. 34 // Connect may also be called again after a call to the Disconnect method.
35 // 35 //
36 virtual int Connect(OldCompletionCallback* callback) = 0; 36 virtual int Connect(OldCompletionCallback* callback) = 0;
37 virtual int Connect(const CompletionCallback& callback) = 0;
37 38
38 // Called to disconnect a socket. Does nothing if the socket is already 39 // Called to disconnect a socket. Does nothing if the socket is already
39 // disconnected. After calling Disconnect it is possible to call Connect 40 // disconnected. After calling Disconnect it is possible to call Connect
40 // again to establish a new connection. 41 // again to establish a new connection.
41 // 42 //
42 // If IO (Connect, Read, or Write) is pending when the socket is 43 // If IO (Connect, Read, or Write) is pending when the socket is
43 // disconnected, the pending IO is cancelled, and the completion callback 44 // disconnected, the pending IO is cancelled, and the completion callback
44 // will not be called. 45 // will not be called.
45 virtual void Disconnect() = 0; 46 virtual void Disconnect() = 0;
46 47
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // identify the motivation. 126 // identify the motivation.
126 bool omnibox_speculation_; 127 bool omnibox_speculation_;
127 bool subresource_speculation_; 128 bool subresource_speculation_;
128 DISALLOW_COPY_AND_ASSIGN(UseHistory); 129 DISALLOW_COPY_AND_ASSIGN(UseHistory);
129 }; 130 };
130 }; 131 };
131 132
132 } // namespace net 133 } // namespace net
133 134
134 #endif // NET_SOCKET_STREAM_SOCKET_H_ 135 #endif // NET_SOCKET_STREAM_SOCKET_H_
OLDNEW
« no previous file with comments | « net/socket/ssl_server_socket_unittest.cc ('k') | net/socket/tcp_client_socket_libevent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698