Public Member Functions | |
GlobalConfigFile () | |
Loads the global config file. | |
GlobalConfigFile (const std::string &appname) | |
Loads the global config file, as well as any application-specific keywords and variables. | |
bool | Save () |
Save the current global config, overwriting or creating as needed. | |
void | SetKey (const std::string &key, const std::string &value) |
Throws std::logic_error if not constructed with an appname. |
Definition at line 131 of file configfile.h.
Barry::GlobalConfigFile::GlobalConfigFile | ( | ) |
Loads the global config file.
Throws ConfigFileError on error, but it is not an error if the config does not exist.
Definition at line 326 of file configfile.cc.
Barry::GlobalConfigFile::GlobalConfigFile | ( | const std::string & | appname | ) |
Loads the global config file, as well as any application-specific keywords and variables.
Use this if you wish to make use of SetKey() and GetKey(), otherwise these functions will throw and exception since they don't have an application name.
Definition at line 334 of file configfile.cc.
bool Barry::GlobalConfigFile::Save | ( | ) |
Save the current global config, overwriting or creating as needed.
Definition at line 411 of file configfile.cc.
References Barry::ConfigFile::CheckPath().
void Barry::GlobalConfigFile::SetKey | ( | const std::string & | key, | |
const std::string & | value | |||
) |
Throws std::logic_error if not constructed with an appname.
Definition at line 441 of file configfile.cc.