WebGetTimeout Function

Action

Gets the currently specified timeouts for Silk Performer's replay engine.

Include file

WebAPI.bdh

Syntax

WebGetTimeout( in nFlag : number ) : number;

Return value

Current timeout value in milliseconds.

Parameter Description
nFlag

Specifies whether to retrieve the timeout value for sending, receiving or connecting. Possible options are:

  • WEB_TIMEOUT_SEND. Gets the value for timeout reported when data cannot be sent to the server.

  • WEB_TIMEOUT_RECV. Gets the value for timeout reported when no data can be received from the server.

  • WEB_TIMEOUT_CONNECT. Gets the value for timeout reported when a connection to a server cannot be established.

Example

transaction TTimeout
  begin
    WebSetTimeout(WEB_TIMEOUT_SEND, 1000);
    WebSetTimeout(WEB_TIMEOUT_RECV, 2000);
    WebSetTimeout(WEB_TIMEOUT_CONNECT, 3000);
    
    print(string(WebGetTimeout(WEB_TIMEOUT_SEND)));
    print(string(WebGetTimeout(WEB_TIMEOUT_RECV)));
    print(string(WebGetTimeout(WEB_TIMEOUT_CONNECT)));
   
  end TTimeout;