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

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

Issue 199048: Add methods for setting socket buffers to the Socket (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 months 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/socket_test_util.h ('k') | net/socket/socks5_client_socket.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) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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_SOCKS5_CLIENT_SOCKET_H_ 5 #ifndef NET_SOCKET_SOCKS5_CLIENT_SOCKET_H_
6 #define NET_SOCKET_SOCKS5_CLIENT_SOCKET_H_ 6 #define NET_SOCKET_SOCKS5_CLIENT_SOCKET_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 30 matching lines...) Expand all
41 // Does the SOCKS handshake and completes the protocol. 41 // Does the SOCKS handshake and completes the protocol.
42 virtual int Connect(CompletionCallback* callback); 42 virtual int Connect(CompletionCallback* callback);
43 virtual void Disconnect(); 43 virtual void Disconnect();
44 virtual bool IsConnected() const; 44 virtual bool IsConnected() const;
45 virtual bool IsConnectedAndIdle() const; 45 virtual bool IsConnectedAndIdle() const;
46 46
47 // Socket methods: 47 // Socket methods:
48 virtual int Read(IOBuffer* buf, int buf_len, CompletionCallback* callback); 48 virtual int Read(IOBuffer* buf, int buf_len, CompletionCallback* callback);
49 virtual int Write(IOBuffer* buf, int buf_len, CompletionCallback* callback); 49 virtual int Write(IOBuffer* buf, int buf_len, CompletionCallback* callback);
50 50
51 virtual bool SetReceiveBufferSize(int32 size);
52 virtual bool SetSendBufferSize(int32 size);
53
51 #if defined(OS_LINUX) 54 #if defined(OS_LINUX)
52 virtual int GetPeerName(struct sockaddr* name, socklen_t* namelen); 55 virtual int GetPeerName(struct sockaddr* name, socklen_t* namelen);
53 #endif 56 #endif
54 57
55 private: 58 private:
56 FRIEND_TEST(SOCKS5ClientSocketTest, IPv6Domain); 59 FRIEND_TEST(SOCKS5ClientSocketTest, IPv6Domain);
57 FRIEND_TEST(SOCKS5ClientSocketTest, FailedDNS); 60 FRIEND_TEST(SOCKS5ClientSocketTest, FailedDNS);
58 FRIEND_TEST(SOCKS5ClientSocketTest, CompleteHandshake); 61 FRIEND_TEST(SOCKS5ClientSocketTest, CompleteHandshake);
59 62
60 enum State { 63 enum State {
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 AddressList addresses_; 145 AddressList addresses_;
143 HostResolver::RequestInfo host_request_info_; 146 HostResolver::RequestInfo host_request_info_;
144 147
145 DISALLOW_COPY_AND_ASSIGN(SOCKS5ClientSocket); 148 DISALLOW_COPY_AND_ASSIGN(SOCKS5ClientSocket);
146 }; 149 };
147 150
148 } // namespace net 151 } // namespace net
149 152
150 #endif // NET_SOCKET_SOCKS5_CLIENT_SOCKET_H_ 153 #endif // NET_SOCKET_SOCKS5_CLIENT_SOCKET_H_
151 154
OLDNEW
« no previous file with comments | « net/socket/socket_test_util.h ('k') | net/socket/socks5_client_socket.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698