method

tty.ReadStream.setKeepAlive

): this;

Configure keep-alive using an options object. See socket.setKeepAlive() for a description of each property.

socket.setKeepAlive({ enable: true, initialDelay: 1000, interval: 1000, count: 10 });
@returns

The socket itself.

enable?: boolean,
initialDelay?: number,
interval?: number,
count?: number
): this;

Configure keep-alive using positional arguments. See socket.setKeepAlive() for a description of each argument.

@param enable

Default: false

@param initialDelay

Default: 0

@param interval

Default: 1000

@param count

Default: 10

@returns

The socket itself.

Referenced types

interface SetKeepAliveOptions