sockpp
Modern C++ socket library wrapper
|
Generic socket address. More...
#include <sock_address.h>
Public Member Functions | |
virtual | ~sock_address () |
Virtual destructor. | |
virtual socklen_t | size () const =0 |
Gets the size of this structure. More... | |
virtual sockaddr * | sockaddr_ptr ()=0 |
Gets a pointer to this object cast to a sockaddr. More... | |
virtual const sockaddr * | sockaddr_ptr () const =0 |
Gets a pointer to this object cast to a sockaddr. More... | |
virtual sa_family_t | family () const |
Gets the network family of the address. More... | |
Generic socket address.
Abstract base class for socket addresses. The underlying C socket functions typically take or return an address as a sockaddr
pointer and length. So derived classes that wrap the
|
inlinevirtual |
Gets the network family of the address.
|
pure virtual |
Gets the size of this structure.
This is equivalent to sizeof(this) but more convenient in some places.
Implemented in sockpp::inet6_address, sockpp::inet_address, sockpp::sock_address_any, and sockpp::unix_address.
|
pure virtual |
Gets a pointer to this object cast to a sockaddr.
Implemented in sockpp::inet6_address, sockpp::inet_address, sockpp::sock_address_any, and sockpp::unix_address.
|
pure virtual |
Gets a pointer to this object cast to a sockaddr.
Implemented in sockpp::inet6_address, sockpp::inet_address, sockpp::sock_address_any, and sockpp::unix_address.