The UdpSocket type provides send and send_to methods, but does not provide a vectored send operation. Such an operation is particularly helpful for datagrams, where separate send operations result in separate datagrams; a vectored send allows sending data from multiple buffers in a single datagram.
This would require calling sendmsg, which supports supplying an iovec. (This should work on Windows as well.)
The
UdpSockettype providessendandsend_tomethods, but does not provide a vectored send operation. Such an operation is particularly helpful for datagrams, where separate send operations result in separate datagrams; a vectored send allows sending data from multiple buffers in a single datagram.This would require calling
sendmsg, which supports supplying an iovec. (This should work on Windows as well.)