5 #ifndef PPAPI_CPP_TCP_SOCKET_H_
6 #define PPAPI_CPP_TCP_SOCKET_H_
8 #include "ppapi/c/ppb_tcp_socket.h"
15 class CompletionCallback;
18 template <
typename T>
class CompletionCallbackWithOutput;
212 #endif // PPAPI_CPP_TCP_SOCKET_H_
int32_t Listen(int32_t backlog, const CompletionCallback &callback)
int32_t SetOption(PP_TCPSocket_Option name, const Var &value, const CompletionCallback &callback)
NetAddress GetLocalAddress() const
int32_t Bind(const NetAddress &addr, const CompletionCallback &callback)
int32_t Accept(const CompletionCallbackWithOutput< TCPSocket > &callback)
int32_t Read(char *buffer, int32_t bytes_to_read, const CompletionCallback &callback)
static bool IsAvailable()
int32_t Connect(const NetAddress &addr, const CompletionCallback &callback)
The NetAddress class represents a network address.
TCPSocket & operator=(const TCPSocket &other)
int32_t Write(const char *buffer, int32_t bytes_to_write, const CompletionCallback &callback)
NetAddress GetRemoteAddress() const
virtual ~TCPSocket()
The destructor.
A generic type used for passing data types between the module and the page.
A reference counted module resource.