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

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

Issue 8831001: base::Bind: Convert Socket::Write. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix alignment. 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_client_socket_nss.cc ('k') | net/socket/ssl_client_socket_openssl.cc » ('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_SSL_CLIENT_SOCKET_OPENSSL_H_ 5 #ifndef NET_SOCKET_SSL_CLIENT_SOCKET_OPENSSL_H_
6 #define NET_SOCKET_SSL_CLIENT_SOCKET_OPENSSL_H_ 6 #define NET_SOCKET_SSL_CLIENT_SOCKET_OPENSSL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 virtual void SetOmniboxSpeculation(); 75 virtual void SetOmniboxSpeculation();
76 virtual bool WasEverUsed() const; 76 virtual bool WasEverUsed() const;
77 virtual bool UsingTCPFastOpen() const; 77 virtual bool UsingTCPFastOpen() const;
78 virtual int64 NumBytesRead() const; 78 virtual int64 NumBytesRead() const;
79 virtual base::TimeDelta GetConnectTimeMicros() const; 79 virtual base::TimeDelta GetConnectTimeMicros() const;
80 80
81 // Socket implementation. 81 // Socket implementation.
82 virtual int Read(IOBuffer* buf, int buf_len, OldCompletionCallback* callback); 82 virtual int Read(IOBuffer* buf, int buf_len, OldCompletionCallback* callback);
83 virtual int Read(IOBuffer* buf, int buf_len, 83 virtual int Read(IOBuffer* buf, int buf_len,
84 const CompletionCallback& callback); 84 const CompletionCallback& callback);
85 virtual int Write(IOBuffer* buf, int buf_len, OldCompletionCallback* callback) ; 85 virtual int Write(IOBuffer* buf, int buf_len,
86 OldCompletionCallback* callback);
87 virtual int Write(IOBuffer* buf, int buf_len,
88 const CompletionCallback& callback);
86 virtual bool SetReceiveBufferSize(int32 size); 89 virtual bool SetReceiveBufferSize(int32 size);
87 virtual bool SetSendBufferSize(int32 size); 90 virtual bool SetSendBufferSize(int32 size);
88 91
89 private: 92 private:
90 bool Init(); 93 bool Init();
91 void DoReadCallback(int result); 94 void DoReadCallback(int result);
92 void DoWriteCallback(int result); 95 void DoWriteCallback(int result);
93 96
94 bool DoTransportIO(); 97 bool DoTransportIO();
95 int DoHandshake(); 98 int DoHandshake();
(...skipping 23 matching lines...) Expand all
119 OldCompletionCallbackImpl<SSLClientSocketOpenSSL> buffer_recv_callback_; 122 OldCompletionCallbackImpl<SSLClientSocketOpenSSL> buffer_recv_callback_;
120 bool transport_send_busy_; 123 bool transport_send_busy_;
121 scoped_refptr<DrainableIOBuffer> send_buffer_; 124 scoped_refptr<DrainableIOBuffer> send_buffer_;
122 bool transport_recv_busy_; 125 bool transport_recv_busy_;
123 scoped_refptr<IOBuffer> recv_buffer_; 126 scoped_refptr<IOBuffer> recv_buffer_;
124 127
125 OldCompletionCallback* old_user_connect_callback_; 128 OldCompletionCallback* old_user_connect_callback_;
126 CompletionCallback user_connect_callback_; 129 CompletionCallback user_connect_callback_;
127 OldCompletionCallback* old_user_read_callback_; 130 OldCompletionCallback* old_user_read_callback_;
128 CompletionCallback user_read_callback_; 131 CompletionCallback user_read_callback_;
129 OldCompletionCallback* user_write_callback_; 132 OldCompletionCallback* old_user_write_callback_;
133 CompletionCallback user_write_callback_;
130 134
131 // Used by Read function. 135 // Used by Read function.
132 scoped_refptr<IOBuffer> user_read_buf_; 136 scoped_refptr<IOBuffer> user_read_buf_;
133 int user_read_buf_len_; 137 int user_read_buf_len_;
134 138
135 // Used by Write function. 139 // Used by Write function.
136 scoped_refptr<IOBuffer> user_write_buf_; 140 scoped_refptr<IOBuffer> user_write_buf_;
137 int user_write_buf_len_; 141 int user_write_buf_len_;
138 142
139 // Set when handshake finishes. 143 // Set when handshake finishes.
(...skipping 29 matching lines...) Expand all
169 State next_handshake_state_; 173 State next_handshake_state_;
170 NextProtoStatus npn_status_; 174 NextProtoStatus npn_status_;
171 std::string npn_proto_; 175 std::string npn_proto_;
172 std::string server_protos_; 176 std::string server_protos_;
173 BoundNetLog net_log_; 177 BoundNetLog net_log_;
174 }; 178 };
175 179
176 } // namespace net 180 } // namespace net
177 181
178 #endif // NET_SOCKET_SSL_CLIENT_SOCKET_OPENSSL_H_ 182 #endif // NET_SOCKET_SSL_CLIENT_SOCKET_OPENSSL_H_
OLDNEW
« no previous file with comments | « net/socket/ssl_client_socket_nss.cc ('k') | net/socket/ssl_client_socket_openssl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698