socketserver.UDPServer()
socketserver.UDPServer() is a Python function in the SocketServer Module category. Creates a UDP server for connectionless datagrams. The syntax is socketserver.UDPServer(server_address, RequestHandlerClass, bind_and_activate=True). Returns: UDPServer object. A typical example: server = UDPServer(("", 9999), Handler)
server.serve_forever(). A close sibling is socketserver.TCPServer(), which creates a TCP server that handles connections. A close sibling is socketserver.ThreadingTCPServer(), which creates a TCP server that handles each connection in a new thread. A close sibling is socketserver.ForkingTCPServer(), which creates a TCP server that forks a process for each connection (Unix). More about this category: Server frameworks — TCPServer, UDPServer, ThreadingTCPServer, ForkingTCPServer. Related SocketServer Module entries: socketserver.TCPServer(), socketserver.ThreadingTCPServer(), socketserver.ForkingTCPServer(). This page is part of the free Python Reference documentation covering 978+ functions, methods, and modules with examples and parameter details. You can try socketserver.UDPServer() immediately in the Python playground, look up unfamiliar terms in the glossary, or return to the Python Reference homepage.