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

Side by Side Diff: trunk/src/net/udp/datagram_server_socket.h

Issue 227083002: Revert 261966 "make SetReceiveBufferSize and SetSendBufferSize r..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 8 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 | « trunk/src/net/spdy/spdy_proxy_client_socket.cc ('k') | trunk/src/net/udp/udp_client_socket.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_UDP_DATAGRAM_SERVER_SOCKET_H_ 5 #ifndef NET_UDP_DATAGRAM_SERVER_SOCKET_H_
6 #define NET_UDP_DATAGRAM_SERVER_SOCKET_H_ 6 #define NET_UDP_DATAGRAM_SERVER_SOCKET_H_
7 7
8 #include "net/base/completion_callback.h" 8 #include "net/base/completion_callback.h"
9 #include "net/base/net_util.h" 9 #include "net/base/net_util.h"
10 #include "net/udp/datagram_socket.h" 10 #include "net/udp/datagram_socket.h"
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 // |callback| is the user callback function to call on complete. 49 // |callback| is the user callback function to call on complete.
50 // Returns a net error code, or ERR_IO_PENDING if the IO is in progress. 50 // Returns a net error code, or ERR_IO_PENDING if the IO is in progress.
51 // If ERR_IO_PENDING is returned, the caller must keep |buf| and |address| 51 // If ERR_IO_PENDING is returned, the caller must keep |buf| and |address|
52 // alive until the callback is called. 52 // alive until the callback is called.
53 virtual int SendTo(IOBuffer* buf, 53 virtual int SendTo(IOBuffer* buf,
54 int buf_len, 54 int buf_len,
55 const IPEndPoint& address, 55 const IPEndPoint& address,
56 const CompletionCallback& callback) = 0; 56 const CompletionCallback& callback) = 0;
57 57
58 // Set the receive buffer size (in bytes) for the socket. 58 // Set the receive buffer size (in bytes) for the socket.
59 // Returns a net error code. 59 virtual bool SetReceiveBufferSize(int32 size) = 0;
60 virtual int SetReceiveBufferSize(int32 size) = 0;
61 60
62 // Set the send buffer size (in bytes) for the socket. 61 // Set the send buffer size (in bytes) for the socket.
63 // Returns a net error code. 62 virtual bool SetSendBufferSize(int32 size) = 0;
64 virtual int SetSendBufferSize(int32 size) = 0;
65 63
66 // Allow the socket to share the local address to which the socket will 64 // Allow the socket to share the local address to which the socket will
67 // be bound with other processes. Should be called before Listen(). 65 // be bound with other processes. Should be called before Listen().
68 virtual void AllowAddressReuse() = 0; 66 virtual void AllowAddressReuse() = 0;
69 67
70 // Allow sending and receiving packets to and from broadcast addresses. 68 // Allow sending and receiving packets to and from broadcast addresses.
71 // Should be called before Listen(). 69 // Should be called before Listen().
72 virtual void AllowBroadcast() = 0; 70 virtual void AllowBroadcast() = 0;
73 71
74 // Join the multicast group with address |group_address|. 72 // Join the multicast group with address |group_address|.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 // some platforms. Returns a network error code. 104 // some platforms. Returns a network error code.
107 virtual int SetDiffServCodePoint(DiffServCodePoint dscp) = 0; 105 virtual int SetDiffServCodePoint(DiffServCodePoint dscp) = 0;
108 106
109 // Resets the thread to be used for thread-safety checks. 107 // Resets the thread to be used for thread-safety checks.
110 virtual void DetachFromThread() = 0; 108 virtual void DetachFromThread() = 0;
111 }; 109 };
112 110
113 } // namespace net 111 } // namespace net
114 112
115 #endif // NET_UDP_DATAGRAM_SERVER_SOCKET_H_ 113 #endif // NET_UDP_DATAGRAM_SERVER_SOCKET_H_
OLDNEW
« no previous file with comments | « trunk/src/net/spdy/spdy_proxy_client_socket.cc ('k') | trunk/src/net/udp/udp_client_socket.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698