base of all plugin interface in elve More...
#include <Plugin.h>
Public Member Functions | |
Plugin () | |
Plugin. | |
po::options_description & | opts () |
get the boost::program_option ctor | |
po::positional_options_description & | pods () |
get the positional options ctor | |
void | configPath (const std::string &path) |
set the path to the configuration ".ini" file of the plugin | |
void | basePath (const QString &path) |
set the path from the excecutable to the folder the plugin is in | |
const QString & | basePath () const |
get the path from the excecutable to the folder the plugin is in | |
const std::string & | configPath () const |
get the path to the configuration ".ini" file of the plugin | |
void | set_vmap (const po::variables_map *map) |
used internally to let option variables be known to the plugin | |
bool | is_set (const std::string &opt) const |
test wheter a particular option variable is set |
base of all plugin interface in elve
This class is mainly an helper aimed at offering basic options and functionnality to every plugin in elve.
void Elve::Plugin::basePath | ( | const QString & | path | ) |
set the path from the excecutable to the folder the plugin is in
path | the path |
Definition at line 19 of file Plugin.cpp.
const QString & Elve::Plugin::basePath | ( | ) | const |
get the path from the excecutable to the folder the plugin is in
Definition at line 23 of file Plugin.cpp.
void Elve::Plugin::configPath | ( | const std::string & | path | ) |
set the path to the configuration ".ini" file of the plugin
path | the path |
Definition at line 9 of file Plugin.cpp.
const std::string & Elve::Plugin::configPath | ( | ) | const |
get the path to the configuration ".ini" file of the plugin
Definition at line 14 of file Plugin.cpp.
bool Elve::Plugin::is_set | ( | const std::string & | opt | ) | const |
test wheter a particular option variable is set
opt | the option name |
Definition at line 35 of file Plugin.cpp.
po::options_description & Elve::Plugin::opts | ( | ) |
get the boost::program_option ctor
Use this to add option to the plugin you're writing, they will be immediatly available as option in the CLI
Definition at line 27 of file Plugin.cpp.
po::positional_options_description & Elve::Plugin::pods | ( | ) |
get the positional options ctor
Use this to add positionnal options as in Plugin::opts()
Definition at line 39 of file Plugin.cpp.
void Elve::Plugin::set_vmap | ( | const po::variables_map * | map | ) |
used internally to let option variables be known to the plugin
map |
Definition at line 31 of file Plugin.cpp.