RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TWebContext.Create Constructor

Creates an initializes an instance of TWebContext.

Pascal
constructor Create(AWebModuleList: TAbstractWebModuleList; ARequest: TWebRequest; AResponse: TWebResponse; ASession: TAbstractWebSession);
C++
__fastcall TWebContext(TAbstractWebModuleList AWebModuleList, TWebRequest ARequest, TWebResponse AResponse, TAbstractWebSession ASession);

Do not create instances of TWebContext. WebSnap applications create a global Web context automatically to represent the current state of the application. To access this global Web context object, use the global WebContext function. 

The TWebContext constructor registers itself with the global WebContext function so that the application can access the Web context using that function, and initializes the properties of the Web context to the values passed in as parameters. 

AWebModuleList is the component that manages the Web modules in the application. It becomes the value of the WebModules property. 

ARequest is the current HTTP request message. It becomes the value of the Request property. 

AResponse is the current response object that the application is filling out. It becomes the value of the Response property. 

ASession is the Session object associated with ARequest. It becomes the value of the Session property. 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!