Share via


SocketType Enumeration

Specifies the socket type, which defines the capabilities of a socket that is used in network communications.

Namespace: System.Net.Sockets
Assembly: System (in system.dll)

Syntax

public enum SocketType

Members

  Member name Description
Dgram A socket that supports datagrams, which are connectionless, unreliable messages of a fixed (typically small) maximum length. Messages might be lost or duplicated and might arrive out of order. A socket of the Dgram type requires no connection before sending and receiving data, and it can communicate with multiple peers. The Dgram socket type uses the InterNetwork address family and the User Datagram Protocol (UDP).
Raw A socket that supports access to the underlying transport protocol. The Raw socket type supports communication that uses protocols such as Internet Control Message Protocol (ICMP) and Internet Group Management Protocol (IGMP). Your application must provide a complete Internet Protocol (IP) header when sending data. Received datagrams return with the IP header and options intact.
Rdm A socket that supports connectionless, message-oriented, reliably delivered messages (RDMs) and preserves message boundaries in data. When you use the Rdm socket type, messages arrive unduplicated and in order. Furthermore, the sender is notified if messages are lost. If you initialize a socket with the Rdm socket type, you do not need a remote host connection before sending and receiving data. The Rdm socket type also enables you to communicate with multiple peers.
Seqpacket A socket that provides connection-oriented and reliable two-way transfer of ordered byte streams across a network. The Seqpacket socket type does not duplicate data, and it preserves boundaries within the data stream. A socket of the Seqpacket type communicates with a single peer and requires a remote host connection before communication can begin.
Stream A socket that supports reliable, two-way, connection-based byte streams without the duplication of data and without preservation of boundaries. A socket of this type communicates with a single peer and requires a remote host connection before communication can begin. The Stream socket type uses the InterNetwork address family and the Transmission Control Protocol (TCP).
Unknown A socket of an unknown type.

Version Information

Available in .NET Micro Framework version 2.0, 2.5

See Also

Reference

System.Net.Sockets Namespace