Manages Network related information. More...
Public Types | |
|
typedef boost::shared_ptr < NetworkManager > | SharedPtr |
Public Member Functions | |
| NetworkManager (void) | |
| Ctor. | |
| ~NetworkManager (void) | |
| Dtor. | |
| void | init () |
| init | |
| bool | isOnline () |
| Returns the Tonido Network online status of the system. | |
| void | networkEnable (bool a_enable) |
| Controls the Tonido Network online/offline status. | |
| bool | networkEnable () |
| Returns whether the Tonido network is enabled or not. | |
| Tonido::Defs::HTTPAccessLevel | HTTPAccess () |
| Returns status of Tonido Web server. | |
| void | HTTPAccess (Tonido::Defs::HTTPAccessLevel a_level) |
| Sets status of Tonido Web Server. | |
| void | networkSpeedLimit (uint32_bt a_speed) |
| Sets the Network Speed Limit. | |
| uint32_bt | networkSpeedLimit () |
| Returns current Network Speed Limit. | |
| void | UPnPEnable (bool a_enable) |
| Controls UPnP status. | |
| bool | UPnPEnable () |
| Returns whether UPnP is enabled or not. | |
| bool | UPnPActive () |
| Returns whether UPnP is enabled currently. | |
| void | UPnPActive (bool a_isUPnPActive) |
| Sets whether UPnP is active. | |
| void | relayEnable (bool a_enable) |
| Controls Relaying status. | |
| bool | relayEnable () |
| Returns whether Relay is enabled or not. | |
| bool | relayActive () |
| Returns whether Relay is enabled currently. | |
| void | relayActive (bool a_isRelayActive) |
| Sets whether Relay is active. | |
| bool | relayIsHTTPS () |
| Returns whether Relay is via HTTPS. | |
| void | relayIsHTTPS (bool a_isRelayHTTPS) |
| Sets whether Relay is via HTTPS. | |
| void | relayStatus (const std::string &a_relayStatus) |
| Sets Relay status. | |
| std::string | relayStatus () |
| Gets Relay status. | |
| void | relayExpiry (const std::string &a_relayExpiry) |
| Sets Relay Expiry. | |
| std::string | relayExpiry () |
| Gets Relay Expiry. | |
| void | relayAddress (const Poco::Net::SocketAddress &a_address) |
| Sets the Relay IP. | |
| Poco::Net::SocketAddress | relayAddress () |
| Gets the Relay IP. | |
| void | clearCurrentRelayIP () |
| Clear Current Relay Server IP. | |
| bool | ipAuthRecordsGet (std::vector< IPData > &a_List, const uint32_bt &a_allowDeny) |
| Retrieves IP authorization records. | |
| bool | ipAuthRecordAdd (const IPData &a_data) |
| Add a new authorization record for an ip address or a range of ip addresses. | |
| bool | ipAuthRecordRemove (const IPData &a_data) |
| Delete an authorization record for an ip address or a range of ip addresses. | |
| bool | isIPBlocked (const Poco::Net::IPAddress &a_address) |
| Checks if a given IP address is blocked. | |
| void | processNetworkOnline () |
| Processes Network Online Event. | |
| void | processNetworkOffline () |
| Processes Network Offline Event. | |
| void | processLogin () |
| Processes Profile Login Event. | |
| void | updateCachedPrivateIP () |
| Update Cached Private IP. | |
| std::string | getCachedPrivateIP () |
| Get Cached Private IP. | |
| void | updateCachedPublicIP (const std::string &a_publicIP) |
| Update Cached Public IP. | |
| std::string | getCachedPublicIP () |
| Get Cached Public IP. | |
| void | addAppExRecord (const std::string &a_tag, const std::string &a_host, int a_port) |
| Add AppEx Record. | |
| void | removeAppExRecord (const std::string &a_tag) |
| Remove AppEx Record. | |
| bool | getAppExRecord (const std::string &a_tag, std::string &a_host, int &port) |
| Get AppEx Record for a specific Tag. | |
Manages Network related information.
| Tonido::Data::NetworkManager::NetworkManager | ( | void | ) |
Ctor.
details if needed ...
| Tonido::Data::NetworkManager::~NetworkManager | ( | void | ) |
Dtor.
details if needed ...
| void Tonido::Data::NetworkManager::clearCurrentRelayIP | ( | ) |
Clear Current Relay Server IP.
Internal Use Only
| void Tonido::Data::NetworkManager::init | ( | ) |
init
| [in] | none | |
| [out] | none |
| bool Tonido::Data::NetworkManager::ipAuthRecordAdd | ( | const IPData & | a_data | ) |
Add a new authorization record for an ip address or a range of ip addresses.
| bool Tonido::Data::NetworkManager::ipAuthRecordRemove | ( | const IPData & | a_data | ) |
Delete an authorization record for an ip address or a range of ip addresses.
| [in] | Start | of IP range |
| [in] | End | of IP range if applicable |
| bool Tonido::Data::NetworkManager::ipAuthRecordsGet | ( | std::vector< IPData > & | a_List, |
| const uint32_bt & | a_allowDeny | ||
| ) |
Retrieves IP authorization records.
| [out] | Authorization | records |
| [in] | 1 | for allowed list and 0 for blocked list |
| bool Tonido::Data::NetworkManager::isIPBlocked | ( | const Poco::Net::IPAddress & | a_address | ) |
Checks if a given IP address is blocked.
| bool Tonido::Data::NetworkManager::isOnline | ( | ) |
Returns the Tonido Network online status of the system.
| [in] | none | |
| [out] | none |
| void Tonido::Data::NetworkManager::networkEnable | ( | bool | a_enable | ) |
Controls the Tonido Network online/offline status.
| [in] | a_enable | flag |
| void Tonido::Data::NetworkManager::networkSpeedLimit | ( | uint32_bt | a_speed | ) |
Sets the Network Speed Limit.
| [in] | a_enable | speed in bytes/sec |
| void Tonido::Data::NetworkManager::relayActive | ( | bool | a_isRelayActive | ) |
Sets whether Relay is active.
Internal Use Only
| void Tonido::Data::NetworkManager::relayAddress | ( | const Poco::Net::SocketAddress & | a_address | ) |
Sets the Relay IP.
Internal Use Only
| Poco::Net::SocketAddress Tonido::Data::NetworkManager::relayAddress | ( | ) |
Gets the Relay IP.
Internal Use Only
| void Tonido::Data::NetworkManager::relayEnable | ( | bool | a_enable | ) |
Controls Relaying status.
| [in] | a_enable | flag |
| void Tonido::Data::NetworkManager::relayExpiry | ( | const std::string & | a_relayExpiry | ) |
Sets Relay Expiry.
Internal Use Only
| std::string Tonido::Data::NetworkManager::relayExpiry | ( | ) |
Gets Relay Expiry.
Internal Use Only
| void Tonido::Data::NetworkManager::relayIsHTTPS | ( | bool | a_isRelayHTTPS | ) |
Sets whether Relay is via HTTPS.
Internal Use Only
| void Tonido::Data::NetworkManager::relayStatus | ( | const std::string & | a_relayStatus | ) |
Sets Relay status.
Internal Use Only
| std::string Tonido::Data::NetworkManager::relayStatus | ( | ) |
Gets Relay status.
Internal Use Only
| void Tonido::Data::NetworkManager::UPnPActive | ( | bool | a_isUPnPActive | ) |
Sets whether UPnP is active.
Internal Use Only
| void Tonido::Data::NetworkManager::UPnPEnable | ( | bool | a_enable | ) |
Controls UPnP status.
| [in] | a_enable | flag |