Create and initialize a new wrapped uv_udp_t
handle.
Bind the UDP handle to an IP address and port.
Request handle to be closed.
Wrapper for uv_close
.
Associate the UDP handle to a remote address and port, so every message sent by this handle is automatically sent to that destination.
Get the remote IP and port of the UDP handle on connected UDP handles
Get the local IP and port of the UDP handle.
Returns true
if the handle referenced, false
otherwise.
Wrapper for uv_has_ref
.
Opens an existing file descriptor or Windows SOCKET as a UDP handle.
Prepare for receiving data.
If the socket has not previously been bound with Udp.bind
it will be bound to 0.0.0.0
and a random port number.
Stop listening for incoming datagrams.
Reference the handle.
Wrapper for uv_ref
.
Send data over the UDP socket.
If the socket has not previously been bound with Udp.bind
it will be bound to 0.0.0.0
and a random port number.
Omit host
and port
for connected UDP handles.
Set broadcast on or off.
Set membership for a multicast address
Set the multicast interface to send or receive data on.
Set IP multicast loop flag. Makes multicast packets loop back to local sockets.
Set the multicast ttl.
Set the time to live.
Same as Udp.send, but won’t queue a send request if it can’t be completed immediately.
Omit host
and port
for connected UDP handles.
Un-reference the handle.
Wrapper for uv_unref
.
Generated using TypeDoc
UDP handles encapsulate UDP communication for both clients and servers.
Wrapper for
uv_udp_t
. See http://docs.libuv.org/en/v1.x/udp.html