RSC  0.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
rsc::plugins::Configurator Class Reference

Instances of this class can be used to configure the #Manager based on configuration options. More...

#include <Configurator.h>

Inheritance diagram for rsc::plugins::Configurator:
Inheritance graph
Collaboration diagram for rsc::plugins::Configurator:
Collaboration graph

Public Member Functions

 Configurator (ManagerPtr manager, const std::vector< boost::filesystem::path > &defaultPath)
 Constructs a Configurator with default plugin search path defaultPath.
virtual ~Configurator ()
- Public Member Functions inherited from rsc::config::OptionHandler
virtual ~OptionHandler ()
virtual void handleOption (const std::vector< std::string > &key, const std::string &value)=0
 This method is called once for each individual option available from a given ConfigSource.

Private Member Functions

void handleOption (const std::vector< std::string > &key, const std::string &value)
void addDefaultPath ()
std::vector< std::string > splitValue (const std::string &value) const

Private Attributes

logging::LoggerPtr logger
ManagerPtr manager
bool pathSet
std::vector
< boost::filesystem::path > 
defaultPath
std::vector< std::string > load

Detailed Description

Instances of this class can be used to configure the #Manager based on configuration options.

Note that the configuration may be performed when the object is destructed.

Author
jmoringe

Definition at line 51 of file Configurator.h.

Constructor & Destructor Documentation

rsc::plugins::Configurator::Configurator ( ManagerPtr  manager,
const std::vector< boost::filesystem::path > &  defaultPath 
)

Constructs a Configurator with default plugin search path defaultPath.

Parameters
managerthe manager to configure
defaultPathA #vector of #boost::filesystem::path objects which should be installed as plugin search path in case no plugin search path is configured.

Definition at line 45 of file Configurator.cpp.

rsc::plugins::Configurator::~Configurator ( )
virtual

Definition at line 53 of file Configurator.cpp.

References addDefaultPath(), defaultPath, load, logger, manager, pathSet, RSCDEBUG, and RSCINFO.

Here is the call graph for this function:

Member Function Documentation

void rsc::plugins::Configurator::addDefaultPath ( )
private

Definition at line 142 of file Configurator.cpp.

References defaultPath, and manager.

Referenced by handleOption(), and ~Configurator().

Here is the caller graph for this function:

void rsc::plugins::Configurator::handleOption ( const std::vector< std::string > &  key,
const std::string &  value 
)
private

Definition at line 96 of file Configurator.cpp.

References addDefaultPath(), load, logger, manager, pathSet, RSCDEBUG, and splitValue().

Here is the call graph for this function:

vector< string > rsc::plugins::Configurator::splitValue ( const std::string &  value) const
private

Definition at line 149 of file Configurator.cpp.

Referenced by handleOption().

Here is the caller graph for this function:

Member Data Documentation

std::vector<boost::filesystem::path> rsc::plugins::Configurator::defaultPath
private

Definition at line 73 of file Configurator.h.

Referenced by addDefaultPath(), and ~Configurator().

std::vector<std::string> rsc::plugins::Configurator::load
private

Definition at line 74 of file Configurator.h.

Referenced by handleOption(), and ~Configurator().

logging::LoggerPtr rsc::plugins::Configurator::logger
private

Definition at line 68 of file Configurator.h.

Referenced by handleOption(), and ~Configurator().

ManagerPtr rsc::plugins::Configurator::manager
private

Definition at line 70 of file Configurator.h.

Referenced by addDefaultPath(), handleOption(), and ~Configurator().

bool rsc::plugins::Configurator::pathSet
private

Definition at line 72 of file Configurator.h.

Referenced by handleOption(), and ~Configurator().


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