UDT Tutorial: Introduction |
UDT is a C++ library. The two classes exposed to application programmers are CUDT and CUDTException.
Using UDT is even simpler than socket programming. Like socket, UDT needs first to bind to a port and/or IP address (using open method), and then listen to a client (as a server) or connect to a server (as a client) to construct the connection. The only difference is that the UDT listen can only accept one connection, not like TCP listen, which can accept multiple client requests.
The parameters, or options, can be tuned by application to gain higher performance or any special purpose. The getOpt and setOpt methods of UDT is just like getsockopt and setsockopt functions of socket.
Data and file can be transfer in either direction after a successful connection.
UDT methods are thread safe.
Any applications with UDT should use the following header and library files.
libudt.so
libudt.a