#include <SaveControl.hpp>
◆ SaveControlImp() [1/3]
geopm::SaveControlImp::SaveControlImp |
( |
const std::vector< m_setting_s > & |
settings | ) |
|
◆ SaveControlImp() [2/3]
geopm::SaveControlImp::SaveControlImp |
( |
const std::string & |
json_string | ) |
|
◆ SaveControlImp() [3/3]
◆ ~SaveControlImp()
virtual geopm::SaveControlImp::~SaveControlImp |
( |
| ) |
|
|
virtualdefault |
◆ json() [1/2]
std::string geopm::SaveControlImp::json |
( |
const std::vector< m_setting_s > & |
settings | ) |
|
|
static |
◆ json() [2/2]
std::string geopm::SaveControlImp::json |
( |
void |
| ) |
const |
|
overridevirtual |
Get saved control settings JSON.
- Returns
- A JSON representation of a vector of m_setting_s structures
Implements geopm::SaveControl.
◆ restore()
void geopm::SaveControlImp::restore |
( |
IOGroup & |
io_group | ) |
const |
|
overridevirtual |
Write all of the control settings to the platform.
Make a sequence of calls to io_group.write_control() with the parameters returned by the settings() method.
- Parameters
-
io_group | [in] An IOGroup that implements controls |
Implements geopm::SaveControl.
◆ settings() [1/3]
◆ settings() [2/3]
◆ settings() [3/3]
Get saved control settings structures.
- Returns
- Vector of setting structures that represent the saved control state.
Implements geopm::SaveControl.
◆ unsaved_controls()
std::set< std::string > geopm::SaveControlImp::unsaved_controls |
( |
const std::set< std::string > & |
all_controls | ) |
const |
|
overridevirtual |
◆ write_json()
void geopm::SaveControlImp::write_json |
( |
const std::string & |
save_path | ) |
const |
|
overridevirtual |
Write the JSON formatted settings to a file.
Writes the string to the specified output file. The file is overwritten if it already exists. An exception is raised if the directory containing the output does not exist, or if the file cannot be created for any other reason.
- Parameters
-
save_path | [in] The file path where the JSON string is written. |
Implements geopm::SaveControl.
The documentation for this class was generated from the following files: