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

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: Added dart2js patch file 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); 230 static intptr_t CreateConnect(const RawAddr& addr,
231 static intptr_t Connect(intptr_t fd, RawAddr addr, const intptr_t port);
232 static intptr_t CreateConnect(RawAddr addr,
233 const intptr_t port); 231 const intptr_t port);
232 static intptr_t CreateBindConnect(const RawAddr& addr,
233 const intptr_t port,
234 const 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 GetNoDelay(intptr_t fd, bool* enabled); 243 static bool GetNoDelay(intptr_t fd, bool* enabled);
243 static bool SetNoDelay(intptr_t fd, bool enabled); 244 static bool SetNoDelay(intptr_t fd, bool enabled);
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
307 308
308 private: 309 private:
309 DISALLOW_ALLOCATION(); 310 DISALLOW_ALLOCATION();
310 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket); 311 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket);
311 }; 312 };
312 313
313 } // namespace bin 314 } // namespace bin
314 } // namespace dart 315 } // namespace dart
315 316
316 #endif // BIN_SOCKET_H_ 317 #endif // BIN_SOCKET_H_
OLDNEW
« no previous file with comments | « runtime/bin/io_natives.cc ('k') | runtime/bin/socket.cc » ('j') | sdk/lib/io/socket.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698