Struct AddressInfo
Defined in File address_info.hpp
Struct Documentation
-
struct AddressInfo
Represents information about an address.
This structure contains information about an address, including the address family, address string, and port number.
Public Members
-
AddressFamily family = AddressFamily::Unspecified
-
std::string address
Represents the address string, e.g. “127.0.0.1” or “localhost”.
-
std::uint16_t port
Represents a port number.
-
inline friend std::ostream &operator<<(std::ostream &ostream, AddressInfo const &address_info)
Overload of the output stream operator for AddressInfo objects.
This operator outputs the information about an AddressInfo object to the specified output stream. The output format depends on the address family of the AddressInfo object.
- Parameters:
ostream – The output stream.
address_info – The AddressInfo object to be outputted.
- Returns:
The output stream after the AddressInfo object has been outputted.
-
AddressFamily family = AddressFamily::Unspecified