5 #ifndef PPAPI_CPP_UDP_SOCKET_H_
6 #define PPAPI_CPP_UDP_SOCKET_H_
8 #include "ppapi/c/ppb_udp_socket.h"
9 #include "ppapi/cpp/net_address.h"
10 #include "ppapi/cpp/pass_ref.h"
11 #include "ppapi/cpp/resource.h"
15 class CompletionCallback;
19 template <
typename T>
class CompletionCallbackWithOutput;
160 #endif // PPAPI_CPP_UDP_SOCKET_H_
int32_t SetOption(PP_UDPSocket_Option name, const Var &value, const CompletionCallback &callback)
NetAddress GetBoundAddress()
The NetAddress class represents a network address.
int32_t SendTo(const char *buffer, int32_t num_bytes, const NetAddress &addr, const CompletionCallback &callback)
virtual ~UDPSocket()
The destructor.
int32_t RecvFrom(char *buffer, int32_t num_bytes, const CompletionCallbackWithOutput< NetAddress > &callback)
A generic type used for passing data types between the module and the page.
static bool IsAvailable()
int32_t Bind(const NetAddress &addr, const CompletionCallback &callback)
A reference counted module resource.
UDPSocket & operator=(const UDPSocket &other)