Internet Direct (Indy) Version 9.0.2 Beta
TIdListenerThread.Run
The Run method provides the main thread of execution for the TIdListenerThread.

procedure Run; override;
Description
Run maintains the list of socket handles allocated by the server and the associated socket handles allocated for client connections. Run creates a TIdTCPServerConnection, which encapulates the server connection to the client, for each socket handle allocated on the server.

Run also requests a TIdPeerThread from the thread manager. The TIdPeerThread represents the thread of execution for each client connection to the server. The peer thread can be a newly created thread or an existing thread from a thread pool. It is the responsibility of the thread manager to determine the appropriate method to handle new thread requests.

Run adds the TIdPeerThread to the list of threads for the server, and calls the Start method of the TIdPeerThread.