The TcpServer class already has a single thread supporting the accept socket and all client connection sockets. Consider some sort of aggregator class that would accept any number of TcpClient and/or UdpSocket instances and support them in a single thread via select() as an alternate threading model.
The
TcpServerclass already has a single thread supporting the accept socket and all client connection sockets. Consider some sort of aggregator class that would accept any number ofTcpClientand/orUdpSocketinstances and support them in a single thread viaselect()as an alternate threading model.