Auto hotspot implementation
This commit is contained in:
@@ -0,0 +1,103 @@
|
||||
|
||||
/*
|
||||
* This file was automatically generated by sdbus-c++-xml2cpp; DO NOT EDIT!
|
||||
*/
|
||||
|
||||
#ifndef __sdbuscpp__dbus_hpp_org_freedesktop_NetworkManager_Device_Wireless_hpp__proxy__H__
|
||||
#define __sdbuscpp__dbus_hpp_org_freedesktop_NetworkManager_Device_Wireless_hpp__proxy__H__
|
||||
|
||||
#include <sdbus-c++/sdbus-c++.h>
|
||||
#include <string>
|
||||
#include <tuple>
|
||||
|
||||
namespace org {
|
||||
namespace freedesktop {
|
||||
namespace NetworkManager {
|
||||
namespace Device {
|
||||
|
||||
class Wireless_proxy
|
||||
{
|
||||
public:
|
||||
static constexpr const char* INTERFACE_NAME = "org.freedesktop.NetworkManager.Device.Wireless";
|
||||
|
||||
protected:
|
||||
Wireless_proxy(sdbus::IProxy& proxy)
|
||||
: proxy_(proxy)
|
||||
{
|
||||
proxy_.uponSignal("AccessPointAdded").onInterface(INTERFACE_NAME).call([this](const sdbus::ObjectPath& access_point){ this->onAccessPointAdded(access_point); });
|
||||
proxy_.uponSignal("AccessPointRemoved").onInterface(INTERFACE_NAME).call([this](const sdbus::ObjectPath& access_point){ this->onAccessPointRemoved(access_point); });
|
||||
}
|
||||
|
||||
~Wireless_proxy() = default;
|
||||
|
||||
virtual void onAccessPointAdded(const sdbus::ObjectPath& access_point) = 0;
|
||||
virtual void onAccessPointRemoved(const sdbus::ObjectPath& access_point) = 0;
|
||||
|
||||
public:
|
||||
std::vector<sdbus::ObjectPath> GetAccessPoints()
|
||||
{
|
||||
std::vector<sdbus::ObjectPath> result;
|
||||
proxy_.callMethod("GetAccessPoints").onInterface(INTERFACE_NAME).storeResultsTo(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
std::vector<sdbus::ObjectPath> GetAllAccessPoints()
|
||||
{
|
||||
std::vector<sdbus::ObjectPath> result;
|
||||
proxy_.callMethod("GetAllAccessPoints").onInterface(INTERFACE_NAME).storeResultsTo(result);
|
||||
return result;
|
||||
}
|
||||
|
||||
void RequestScan(const std::map<std::string, sdbus::Variant>& options)
|
||||
{
|
||||
proxy_.callMethod("RequestScan").onInterface(INTERFACE_NAME).withArguments(options);
|
||||
}
|
||||
|
||||
public:
|
||||
std::string HwAddress()
|
||||
{
|
||||
return proxy_.getProperty("HwAddress").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
std::string PermHwAddress()
|
||||
{
|
||||
return proxy_.getProperty("PermHwAddress").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
uint32_t Mode()
|
||||
{
|
||||
return proxy_.getProperty("Mode").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
uint32_t Bitrate()
|
||||
{
|
||||
return proxy_.getProperty("Bitrate").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
std::vector<sdbus::ObjectPath> AccessPoints()
|
||||
{
|
||||
return proxy_.getProperty("AccessPoints").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
sdbus::ObjectPath ActiveAccessPoint()
|
||||
{
|
||||
return proxy_.getProperty("ActiveAccessPoint").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
uint32_t WirelessCapabilities()
|
||||
{
|
||||
return proxy_.getProperty("WirelessCapabilities").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
int64_t LastScan()
|
||||
{
|
||||
return proxy_.getProperty("LastScan").onInterface(INTERFACE_NAME);
|
||||
}
|
||||
|
||||
private:
|
||||
sdbus::IProxy& proxy_;
|
||||
};
|
||||
|
||||
}}}} // namespaces
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user