Topic Path: Symbol Reference > Classes > TIdHTTPSession Class > TIdHTTPSession Methods > CreateInitialized Constructor
ContentsIndexHome
PreviousUpNext
TIdHTTPSession.CreateInitialized Constructor

Constructor for the object instance.

constructor CreateInitialized(
    AOwner: TIdHTTPCustomSessionList; 
    const SessionID: string; 
    const RemoteIP: string
); virtual;
Parameters 
Description 
AOwner 
Session list that owns the object instance.
 
SessionID 
Session identifier for the object instance.
 
RemoteIP 
IP address for the remote host for the session. 

CreateInitialized is the constructor for the object instance. CreateInitialized creates a new HTTP session, and sets the value for properties in the HTTP session including the SessionID, RemoteHost, Content, Owner, and LastTimestamp. 

The session identifier is set to the value specified in SessionID

RemoteHost is set to the value specified in RemoteIP. 

LastTimeStamp is set to the current date and time on the HTTP server to indicate when the HTTP session was last accessed. 

AOwner is the owner of the object instance, and when assigned, should reflect the TIdHTTPCustomSessionList that owns the session object instance. AOwner is used to trigger the OnSessionStart event handler to perform session maintenance specific to the server implementation. ` 

Resources required for the Content property are allocated in Create

CreateInitialized is called from the CreateSession method in TIdHTTPDefaultSessionList, where a new session is created and added to the session list for the server. 

Use Create to allocate a new HTTP session when persistent state is not maintained in the HTTP server implementation. 

Use Destroy to free the object instance.

Copyright 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Post feedback to the Indy Docs Newsgroup.