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

Side by Side Diff: runtime/bin/socket.h

Issue 908873002: Add support to specify the source address for socket connect (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix Windows build Created 5 years, 10 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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef BIN_SOCKET_H_ 5 #ifndef BIN_SOCKET_H_
6 #define BIN_SOCKET_H_ 6 #define BIN_SOCKET_H_
7 7
8 #include "platform/globals.h" 8 #include "platform/globals.h"
9 9
10 #include "bin/builtin.h" 10 #include "bin/builtin.h"
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 }; 220 };
221 221
222 static bool Initialize(); 222 static bool Initialize();
223 static intptr_t Available(intptr_t fd); 223 static intptr_t Available(intptr_t fd);
224 static intptr_t Read(intptr_t fd, void* buffer, intptr_t num_bytes); 224 static intptr_t Read(intptr_t fd, void* buffer, intptr_t num_bytes);
225 static intptr_t Write(intptr_t fd, const void* buffer, intptr_t num_bytes); 225 static intptr_t Write(intptr_t fd, const void* buffer, intptr_t num_bytes);
226 static intptr_t SendTo( 226 static intptr_t SendTo(
227 intptr_t fd, const void* buffer, intptr_t num_bytes, RawAddr addr); 227 intptr_t fd, const void* buffer, intptr_t num_bytes, RawAddr addr);
228 static intptr_t RecvFrom( 228 static intptr_t RecvFrom(
229 intptr_t fd, void* buffer, intptr_t num_bytes, RawAddr* addr); 229 intptr_t fd, void* buffer, intptr_t num_bytes, RawAddr* addr);
230 static intptr_t Create(RawAddr addr);
231 static intptr_t Connect(intptr_t fd, RawAddr addr, const intptr_t port);
232 static intptr_t CreateConnect(RawAddr addr, 230 static intptr_t CreateConnect(RawAddr addr,
233 const intptr_t port); 231 const intptr_t port);
232 static intptr_t CreateBindConnect(RawAddr addr,
233 const intptr_t port,
234 RawAddr source_addr);
234 static intptr_t CreateBindDatagram( 235 static intptr_t CreateBindDatagram(
235 RawAddr* addr, intptr_t port, bool reuseAddress); 236 RawAddr* addr, intptr_t port, bool reuseAddress);
236 static intptr_t GetPort(intptr_t fd); 237 static intptr_t GetPort(intptr_t fd);
237 static SocketAddress* GetRemotePeer(intptr_t fd, intptr_t* port); 238 static SocketAddress* GetRemotePeer(intptr_t fd, intptr_t* port);
238 static void GetError(intptr_t fd, OSError* os_error); 239 static void GetError(intptr_t fd, OSError* os_error);
239 static int GetType(intptr_t fd); 240 static int GetType(intptr_t fd);
240 static intptr_t GetStdioHandle(intptr_t num); 241 static intptr_t GetStdioHandle(intptr_t num);
241 static void Close(intptr_t fd); 242 static void Close(intptr_t fd);
242 static bool SetNonBlocking(intptr_t fd); 243 static bool SetNonBlocking(intptr_t fd);
243 static bool SetBlocking(intptr_t fd); 244 static bool SetBlocking(intptr_t fd);
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 310
310 private: 311 private:
311 DISALLOW_ALLOCATION(); 312 DISALLOW_ALLOCATION();
312 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket); 313 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket);
313 }; 314 };
314 315
315 } // namespace bin 316 } // namespace bin
316 } // namespace dart 317 } // namespace dart
317 318
318 #endif // BIN_SOCKET_H_ 319 #endif // BIN_SOCKET_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698