The System.Net.Sockets namespace provides a managed implementation of the Windows Sockets (Winsock) interface for developers who need to tightly control access to the network.
The TCPClient, TCPListener, and UDPClient classes encapsulate the details of creating TCP and UDP connections to the Internet.
Class | Description |
---|---|
class LingerOption | Contains information about a socket's linger time, the amount of time it will remain after closing if data remains to be sent. |
class MulticastOption | Contains IP address values for IP multicast packets. |
class NetworkStream | Provides the underlying stream of data for network access. |
class Socket | Implements the Berkeley sockets interface. |
class SocketException | The exception that is thrown when a socket error occurs. |
class TcpClient | Provides client connections for TCP network services. |
class TcpListener | Listens for connections from TCP network clients. |
class UdpClient | Provides User Datagram Protocol (UDP) network services. |
Enumeration | Description |
---|---|
enumeration AddressFamily | Specifies the addressing scheme that an instance of the Socket class can use. |
enumeration ProtocolFamily | Specifies the type of protocol that an instance of the Socket class can use. |
enumeration ProtocolType | Specifies the protocols that the Socket class supports. |
enumeration SelectMode | Defines the polling modes for the Socket.Poll method. |
enumeration SocketFlags | Provides constant values for socket messages. |
enumeration SocketOptionLevel | Defines socket option levels for the Socket.SetSocketOption and Socket.GetSocketOption methods. |
enumeration SocketOptionName | Defines socket option names for the Socket class. |
enumeration SocketShutdown | Defines constants used by the Socket.Shutdown method. |
enumeration SocketType | Specifies the type of socket an instance of the Socket class represents. |