Table of Contents

Class LingerOption

Namespace
System.Net.Sockets
Assembly
System.Net.Sockets.TcpClient.dll

Contains information for a socket's linger time, the amount of time it will remain after closing if data remains to be sent.

public class LingerOption
Inheritance
LingerOption
Inherited Members
Extension Methods

Constructors

LingerOption(bool, int)

Initializes a new instance of the LingerOption

public LingerOption(bool enable, int seconds)

Parameters

enable bool

Enable or disable option.

seconds int

Number of seconds to linger after close.

Properties

Enabled

Enables or disables lingering after close.

public bool Enabled { get; set; }

Property Value

bool

LingerTime

The amount of time, in seconds, to remain connected after a close.

public int LingerTime { get; set; }

Property Value

int