#include <Network.h>
◆ EMESSAGE
Enumerator |
---|
SERVICES_UP | |
SERVICES_DOWN | |
◆ CNetworkBase()
CNetworkBase::CNetworkBase |
( |
| ) |
|
◆ ~CNetworkBase()
CNetworkBase::~CNetworkBase |
( |
| ) |
|
|
virtual |
◆ GetFirstConnectedInterface()
◆ GetHostName()
bool CNetworkBase::GetHostName |
( |
std::string & | hostname | ) |
|
|
virtual |
◆ GetInterfaceList()
◆ GetIpStr()
std::string CNetworkBase::GetIpStr |
( |
const sockaddr * | sa | ) |
|
|
static |
IPv6/IPv4 compatible conversion of host IP address.
- Parameters
-
- Returns
- Function converts binary structure sockaddr to std::string. It can read sockaddr_in and sockaddr_in6, cast as (sockaddr*). IPv4 address is returned in the format x.x.x.x (where x is 0-255), IPv6 address is returned in it's canonised form. On error (or no IPv6/v4 valid input) empty string is returned.
◆ GetMaskByPrefixLength()
std::string CNetworkBase::GetMaskByPrefixLength |
( |
uint8_t | prefixLength | ) |
|
|
static |
convert prefix length of IPv4 address to IP mask representation
- Parameters
-
- Returns
◆ GetNameServers()
virtual std::vector< std::string > CNetworkBase::GetNameServers |
( |
void | | ) |
|
|
pure virtual |
◆ GetNetwork()
std::unique_ptr< CNetworkBase > CNetworkBase::GetNetwork |
( |
| ) |
|
|
static |
◆ GetServices()
◆ HasInterfaceForIP()
bool CNetworkBase::HasInterfaceForIP |
( |
unsigned long | address | ) |
|
◆ IsAvailable()
◆ IsConnected()
◆ IsLocalHost()
bool CNetworkBase::IsLocalHost |
( |
const std::string & | hostname | ) |
|
◆ NetworkMessage()
◆ ParseHex()
int CNetworkBase::ParseHex |
( |
char * | str, |
|
|
unsigned char * | addr ) |
|
static |
◆ PingHost() [1/2]
virtual bool CNetworkBase::PingHost |
( |
unsigned long | host, |
|
|
unsigned int | timeout_ms = 2000 ) |
|
pure virtual |
◆ PingHost() [2/2]
bool CNetworkBase::PingHost |
( |
unsigned long | host, |
|
|
unsigned short | port, |
|
|
unsigned int | timeout_ms = 2000, |
|
|
bool | readability_check = false ) |
◆ WaitForNet()
void CNetworkBase::WaitForNet |
( |
| ) |
|
◆ WakeOnLan()
bool CNetworkBase::WakeOnLan |
( |
const char * | mac | ) |
|
◆ m_services
The documentation for this class was generated from the following files: