Represents a socket address. This class is an abstract base class.
Remarks
The SocketAddress
class provides the functionality to represent a socket address. Socket addresses are used to specify network endpoints for socket operations. This class is abstract and is not intended for direct instantiation. Instead, derived classes like IPv4SocketAddress
and IPv6SocketAddress
provide concrete implementations for specific address families.
Instances of SocketAddress
are typically created and managed by the .NET networking classes, such as Socket
and EndPoint
. You generally do not need to create SocketAddress
objects directly unless you are implementing custom network protocols or working at a very low level.
Inheritance Hierarchy
System.Object
System.Net.Sockets.SocketAddress
Derived Classes
System.Net.Sockets.IPv4SocketAddress
System.Net.Sockets.IPv6SocketAddress
Constructors
SocketAddress
class with the specified address family and size. This constructor is protected and intended for use by derived classes.SocketAddress
class with the specified address family. This constructor is protected and intended for use by derived classes.