Introduction - If you have any usage issues, please Google them yourself
C# multi-threaded network communication system is composed of three core thread throughout the composition, by the. NET thread pool unified management: a client connection request listening thread: ListenClientRequest (), loop listening client connection request. If you have, testing the client IP, to see if the same observation equipment, and then create a client-side TSession object, and through Socket asynchronous call methods BeginReceive () to receive data packets, EndReceive () processing of data packet data packet processing threads: HandleDatagrams ( ), cyclic test data packet queue _datagramQueue, the completion of the packet parsing to determine the type, storage, etc. the client state detection thread: CheckClientState (), loop checks the client session