Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
|
Ivan Posva
2012/01/10 00:28:09
.
Mads Ager (google)
2012/01/10 06:55:05
Done.
| |
| 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 "bin/builtin.h" | 8 #include "bin/builtin.h" |
| 9 | |
| 10 #include "platform/globals.h" | 9 #include "platform/globals.h" |
| 11 | 10 |
| 12 | 11 |
| 13 class Socket { | 12 class Socket { |
| 14 public: | 13 public: |
| 15 static bool Initialize(); | 14 static bool Initialize(); |
| 16 static intptr_t Available(intptr_t fd); | 15 static intptr_t Available(intptr_t fd); |
| 17 static int Read(intptr_t fd, void* buffer, intptr_t num_bytes); | 16 static int Read(intptr_t fd, void* buffer, intptr_t num_bytes); |
| 18 static int Write(intptr_t fd, const void* buffer, intptr_t num_bytes); | 17 static int Write(intptr_t fd, const void* buffer, intptr_t num_bytes); |
| 19 static intptr_t CreateConnect(const char* host, const intptr_t port); | 18 static intptr_t CreateConnect(const char* host, const intptr_t port); |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 30 static intptr_t Accept(intptr_t fd); | 29 static intptr_t Accept(intptr_t fd); |
| 31 static intptr_t CreateBindListen(const char* bindAddress, | 30 static intptr_t CreateBindListen(const char* bindAddress, |
| 32 intptr_t port, | 31 intptr_t port, |
| 33 intptr_t backlog); | 32 intptr_t backlog); |
| 34 | 33 |
| 35 DISALLOW_ALLOCATION(); | 34 DISALLOW_ALLOCATION(); |
| 36 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket); | 35 DISALLOW_IMPLICIT_CONSTRUCTORS(ServerSocket); |
| 37 }; | 36 }; |
| 38 | 37 |
| 39 #endif // BIN_SOCKET_H_ | 38 #endif // BIN_SOCKET_H_ |
| OLD | NEW |