Internet Direct (Indy)
Home
PreviousUpNext
TIdCustomTCPServer.ContextClass Property

Class reference used to create new executable tasks for client connections to the server.

Pascal
property ContextClass: TIdContextClass;

ContextClass is a TIdContextClass property that represents the class reference used to create new executable tasks for client connections to the server. ContextClass is a assigned a TIdContext class reference during initialization of the component. 

ContextClass is used during execution of the listener thread(s) (TIdListenerThread) for the server to create the TIdContext instances stored in the Contexts property. 

The context provides the client connection and IOHandler for the accepted connection request, the list of Contexts for the server, and the thread or fiber (Yarn) acquired from the Scheduler for controlling execution the task for the client connection. 

The TIdContext uses protected procedures from the server in its OnBeforeRun, OnRun, and OnAfterRun event handlers. The Scheduler is used to start execution of the task using the Yarn (thread or fiber) acquired for the TIdContext.

Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.