geopm 3.2.1.dev535+ga96c120fc
GEOPM - Global Extensible Open Power Manager
Loading...
Searching...
No Matches
geopm::ServiceProxyImp Class Reference

#include <ServiceProxy.hpp>

Inheritance diagram for geopm::ServiceProxyImp:
Collaboration diagram for geopm::ServiceProxyImp:

Public Member Functions

 ServiceProxyImp ()
 ServiceProxyImp (std::shared_ptr< SDBus > bus)
virtual ~ServiceProxyImp ()=default
void platform_get_user_access (std::vector< std::string > &signal_names, std::vector< std::string > &control_names) override
 Calls the PlatformGetUserAccess API defined in the io.github.geopm D-Bus namespace.
std::vector< signal_info_s > platform_get_signal_info (const std::vector< std::string > &signal_names) override
 Calls the PlatformGetSignalInfo API defined in the io.github.geopm D-Bus namespace.
std::vector< control_info_s > platform_get_control_info (const std::vector< std::string > &control_names) override
 Calls the PlatformGetControlInfo API defined in the io.github.geopm D-Bus namespace.
void platform_open_session (void) override
 Calls the PlatformOpenSession API defined in the io.github.geopm D-Bus namespace.
void platform_close_session (void) override
 Calls the PlatformCloseSession API defined in the io.github.geopm D-Bus namespace.
void platform_start_batch (const std::vector< struct geopm_request_s > &signal_config, const std::vector< struct geopm_request_s > &control_config, int &server_pid, std::string &server_key) override
 Calls the PlatformStartBatch API defined in the io.github.geopm D-Bus namespace.
void platform_stop_batch (int server_pid) override
 Calls the PlatformStopBatch API defined in the io.github.geopm D-Bus namespace.
double platform_read_signal (const std::string &signal_name, int domain, int domain_idx) override
 Calls the PlatformReadSignal API defined in the io.github.geopm D-Bus namespace.
void platform_write_control (const std::string &control_name, int domain, int domain_idx, double setting) override
 Calls the PlatformWriteControl API defined in the io.github.geopm D-Bus namespace.
void platform_restore_control () override
 Calls the PlatformRestoreControl API defined in the io.github.geopm D-Bus namespace.
std::string topo_get_cache (void) override
 Calls the TopoGetCache API defined in the io.github.geopm D-Bus namespace.
void platform_start_profile (const std::string &profile_name) override
void platform_stop_profile (const std::vector< std::string > &region_names) override
std::vector< int > platform_get_profile_pids (const std::string &profile_name) override
std::vector< std::string > platform_pop_profile_region_names (const std::string &profile_name) override
Public Member Functions inherited from geopm::ServiceProxy
 ServiceProxy ()=default
 ServiceProxy constructor.
virtual ~ServiceProxy ()=default
 ServiceProxy destructor.

Additional Inherited Members

Static Public Member Functions inherited from geopm::ServiceProxy
static std::unique_ptr< ServiceProxy > make_unique (void)
 Create a unique pointer to a ServiceProxy object.

Constructor & Destructor Documentation

◆ ServiceProxyImp() [1/2]

geopm::ServiceProxyImp::ServiceProxyImp ( )

◆ ServiceProxyImp() [2/2]

geopm::ServiceProxyImp::ServiceProxyImp ( std::shared_ptr< SDBus > bus)

◆ ~ServiceProxyImp()

virtual geopm::ServiceProxyImp::~ServiceProxyImp ( )
virtualdefault

Member Function Documentation

◆ platform_close_session()

void geopm::ServiceProxyImp::platform_close_session ( void )
overridevirtual

Calls the PlatformCloseSession API defined in the io.github.geopm D-Bus namespace.

Implements geopm::ServiceProxy.

◆ platform_get_control_info()

std::vector< control_info_s > geopm::ServiceProxyImp::platform_get_control_info ( const std::vector< std::string > & control_names)
overridevirtual

Calls the PlatformGetControlInfo API defined in the io.github.geopm D-Bus namespace.

Parameters
control_names[in] Vector of strings containing all control names to query.
Returns
Vector of structures describing the queried controls

Implements geopm::ServiceProxy.

◆ platform_get_profile_pids()

std::vector< int > geopm::ServiceProxyImp::platform_get_profile_pids ( const std::string & profile_name)
overridevirtual

Implements geopm::ServiceProxy.

◆ platform_get_signal_info()

std::vector< signal_info_s > geopm::ServiceProxyImp::platform_get_signal_info ( const std::vector< std::string > & signal_names)
overridevirtual

Calls the PlatformGetSignalInfo API defined in the io.github.geopm D-Bus namespace.

Parameters
signal_names[in] Vector of strings containing all signal names to query.
Returns
Vector of structures describing the queried signals

Implements geopm::ServiceProxy.

◆ platform_get_user_access()

void geopm::ServiceProxyImp::platform_get_user_access ( std::vector< std::string > & signal_names,
std::vector< std::string > & control_names )
overridevirtual

Calls the PlatformGetUserAccess API defined in the io.github.geopm D-Bus namespace.

Parameters
signal_names[out] Vector of strings containing all signals that the calling process has access to.
control_names[out] Vector of strings containing all controls that the calling process has access to.

Implements geopm::ServiceProxy.

◆ platform_open_session()

void geopm::ServiceProxyImp::platform_open_session ( void )
overridevirtual

Calls the PlatformOpenSession API defined in the io.github.geopm D-Bus namespace.

Implements geopm::ServiceProxy.

◆ platform_pop_profile_region_names()

std::vector< std::string > geopm::ServiceProxyImp::platform_pop_profile_region_names ( const std::string & profile_name)
overridevirtual

Implements geopm::ServiceProxy.

◆ platform_read_signal()

double geopm::ServiceProxyImp::platform_read_signal ( const std::string & signal_name,
int domain,
int domain_idx )
overridevirtual

Calls the PlatformReadSignal API defined in the io.github.geopm D-Bus namespace.

Parameters
signal_name[in] Name of the signal to read
domain[in] Topology domain to read the signal from. One of the geopm_domain_e values defined in geopm_topo.h.
domain_idx[in] Index of the domain to read the signal from.
Returns
The value of the signal read

Implements geopm::ServiceProxy.

◆ platform_restore_control()

void geopm::ServiceProxyImp::platform_restore_control ( )
overridevirtual

Calls the PlatformRestoreControl API defined in the io.github.geopm D-Bus namespace.

Implements geopm::ServiceProxy.

◆ platform_start_batch()

void geopm::ServiceProxyImp::platform_start_batch ( const std::vector< struct geopm_request_s > & signal_config,
const std::vector< struct geopm_request_s > & control_config,
int & server_pid,
std::string & server_key )
overridevirtual

Calls the PlatformStartBatch API defined in the io.github.geopm D-Bus namespace.

Parameters
signal_config[in] Vector of signal requests that will be supported by the batch server that is created.
control_config[in] Vector of control requests that will be supported by the batch server that is created.
server_pid[out] Linux PID of the server process created.
server_key[out] Unique key used to connect to the created server.

Implements geopm::ServiceProxy.

◆ platform_start_profile()

void geopm::ServiceProxyImp::platform_start_profile ( const std::string & profile_name)
overridevirtual

Implements geopm::ServiceProxy.

◆ platform_stop_batch()

void geopm::ServiceProxyImp::platform_stop_batch ( int server_pid)
overridevirtual

Calls the PlatformStopBatch API defined in the io.github.geopm D-Bus namespace.

Parameters
server_pid[in] The Linux PID of the batch server to stop.

Implements geopm::ServiceProxy.

◆ platform_stop_profile()

void geopm::ServiceProxyImp::platform_stop_profile ( const std::vector< std::string > & region_names)
overridevirtual

Implements geopm::ServiceProxy.

◆ platform_write_control()

void geopm::ServiceProxyImp::platform_write_control ( const std::string & control_name,
int domain,
int domain_idx,
double setting )
overridevirtual

Calls the PlatformWriteControl API defined in the io.github.geopm D-Bus namespace.

Parameters
control_name[in] Name of the control to write
domain[in] Topology domain to write to. One of the geopm_domain_e values defined in geopm_topo.h.
domain_idx[in] Index of the domain to write to.
setting[in] Value of the control to write.

Implements geopm::ServiceProxy.

◆ topo_get_cache()

std::string geopm::ServiceProxyImp::topo_get_cache ( void )
overridevirtual

Calls the TopoGetCache API defined in the io.github.geopm D-Bus namespace.

Returns
The string buffer defining the system topology

Implements geopm::ServiceProxy.


The documentation for this class was generated from the following files: