Internet Direct (Indy)
|
Checks state and status information on the transport for the IO handler.
procedure CheckForDisconnect( ARaiseExceptionIfDisconnected: Boolean = True; AIgnoreBuffer: Boolean = False ); virtual; abstract;
Parameters |
Description |
ARaiseExceptionIfDisconnected |
Indicates if exceptions are raised when the connection has closed prematurely. |
AIgnoreBuffer |
Indicates if data in the Indy buffer is ignored when the connection has closed prematurely. |
CheckForDisconnect is an abstract virtual procedure in TIdIOHandler. CheckForDisconnect must be overridden in a descendant class to allow inspecting the status of the connection prior to or following a method call that performs an IO operation.
CheckForDisconnect is used primarily to ensure that state and status properties for the IOHandler are synchronized with the underlying transport mechanism.
In descendant classes, CheckForDisconnect must not delay when inspecting the connection. The method should not raise any exceptions directly, but may call methods in the descendant designed for that purpose when ARaiseExceptionIfDisconnected contains True.
CheckForDisconnect may trigger the OnStatus event handler for the connection if the connection state has changed based on values detected in the method.
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. |