TsgcSSEClient › Properties › ReadyState

ReadyState Property

Current state of the connection: connecting, open or closed.

Syntax

property ReadyState: TsgcSSEReadyState read GetReadyState;
// TsgcSSEReadyState = (sseConnecting, sseOpen, sseClosed)

Default Value

sseClosed

Remarks

Read-only, public. sseConnecting while a connection attempt is running or the client waits to reconnect, sseOpen after the server has accepted the stream and OnOpen has fired, and sseClosed before Open and after the client has stopped.

Example


case oSSE.ReadyState of
  sseConnecting: ShowMessage('connecting');
  sseOpen: ShowMessage('open');
  sseClosed: ShowMessage('closed');
end;

Back to Properties