property OnAcceptConnection: TScAcceptConnectionEvent;
type
TScAcceptConnectionEvent = procedure (Sender: TObject; Connection: TScTCPConnection; var Cancel: boolean) of object;
Description
Occurs when a new TCP/IP connection is established, in case there is a socket connection to the port that the HTTP server is listening on.
To cancel the connection, set the Cancel property to True. This can be done for a specific IP address by using the Connection.GetRemoteIP property or for any other reason.
To proceed working with the connection, use the Connection object. For exchanging data, you can use the Connection.Read and Connection.Write methods.
Parameters:
• | Sender - the object whose event handler is called; |
• | Connection - wraps the information about the socket that is trying to connect to the HTTP server; |
• | Cancel - determines whether a connection to the specified TCP/IP socket will be established. Set Cancel to True, if you want to cancel the process of establishing the connection. |