|
ifw-sup
1.0.0
|
#include <config.hpp>
Public Member Functions | |
| Config () | |
| virtual | ~Config () |
| bool | ParseOptions (int argc, char *argv[]) |
| void | LoadConfig (const std::string &filename="") |
| const std::string | GetServerId () const |
| const std::string | GetMsgReplierEndpoint () const |
| const std::string | GetDbEndpoint () const |
| const std::string | GetPubEndpoint () const |
| const timeval | GetDbTimeout () const |
| const std::string | GetSmScxmlFilename () const |
| const std::string | GetConfigFilename () const |
| const std::string | GetProcName () const |
| const std::string | GetLogLevel () const |
| std::optional< bool > | GetReplyOk (const std::string &name) const |
| std::optional< int > | GetReplyDelay (const std::string &name) const |
| std::optional< std::string > | GetReplyErrorMessage (const std::string &name) const |
| ReplyConfigData * | GetCmdReplyData (const std::string &name) |
| virtual void | GetConfigList (std::vector< std::string > &cfg_list) |
| Get configuration list. More... | |
| const unsigned int | GetCmdTout () |
| GetCmdTout. More... | |
| const int | GetNumCommands () override |
| const std::string | GetCommandName (const int &cmd_index) |
| void | SetCmdTout (const unsigned int cmd_tout) |
| SetCmdTout. More... | |
| const std::string | GetConfigAsString () const |
| Get the actual configuration as a string. More... | |
| void | SetReplyOk (const std::string &name, const bool &flag) |
| void | SetReplyDelay (const std::string &name, const int &delay) |
| void | SetReplyErrorMessage (const std::string &name, const std::string &msg) |
| Config (const Config &)=delete | |
| Config & | operator= (const Config &)=delete |
| Disable copy constructor. More... | |
This class provide access to the command line options and the configuration parameters stored in the configuration file.
| sup::subsim::common::Config::Config | ( | ) |
Default constructor.
Initialize application configuration attributes by
|
virtual |
Default destructor.
|
delete |
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
| const std::string sup::subsim::common::Config::GetCommandName | ( | const int & | cmd_index | ) |
|
virtual |
Get the actual configuration as a string.
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Get configuration list.
| cfg_list | List of all configuration parameters. |
This method returs the complete of configuration parameters handled by this class. This method is used to dump the list into the DB.
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
overridevirtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
This method load from a configuration file the application configuration overriding the initialization done in the constructor and the command line options.
| [in] | filename | Application configuration filename. |
Implements sup::subsim::common::IConfig.
|
virtual |
This method parses the command line parameters overriding the initialization done in the constructor.
| [in] | argc | Number of command line options. |
| [in] | argv | Pointer to the array of command line options. |
Implements sup::subsim::common::IConfig.
| void sup::subsim::common::Config::SetCmdTout | ( | const unsigned int | cmd_tout | ) |
SetCmdTout.
| cmd_tout | new command timeout |
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.
|
virtual |
Implements sup::subsim::common::IConfig.