|
torc-master
|
#include <ParameterMap.hpp>
Collaboration diagram for torc::generic::ParameterMap:Data Structures | |
| struct | ParamData |
Public Types | |
| typedef SymTab< std::string, ParameterSharedPtr, true > | TabParams |
| typedef boost::shared_ptr < TabParams > | TabParamsPtr |
Public Member Functions | |
| ParameterSharedPtr | get (const ParameterContext &inContext, const std::string &inName) const |
| void | set (const ParameterContext &inContext, const std::string &inName, const ParameterSharedPtr &inParam) |
| void | getAllParameters (const ParameterContext &inContext, std::map< std::string, ParameterSharedPtr > &outParams) const |
| void | getOverriddenParameters (const ParameterContext &inContext, std::map< std::string, ParameterSharedPtr > &outParams) const |
| template<typename _Action > | |
| void | applyOnAllParameters (const ParameterContext &inContext, const _Action &action) throw (Error) |
| template<typename _Action > | |
| void | applyOnOverriddenParameters (const ParameterContext &inContext, const _Action &action) throw (Error) |
| ParameterContext | getNewContext () |
| void | registerContext (const ParameterContext &inContext, const ParameterContext &inParentContext=ParameterContext()) throw (Error) |
| bool | isContextRegistered (const ParameterContext &inContext) const |
| void | unregisterContext (const ParameterContext &inContext) |
| ParameterMap () | |
| ~ParameterMap () throw () | |
| ParameterMap (const ParameterMap &source) | |
| ParameterMap & | operator= (const ParameterMap &source) |
Private Types | |
| typedef boost::shared_ptr < ParamData > | ParamDataPtr |
Private Attributes | |
| SymTab< ParameterContext, ParamDataPtr > | mParameters |
| ParameterContext | mNextContext |
Stores Name-Parameter mappings. This map can be used to get and set values for different parameters.
Definition at line 37 of file ParameterMap.hpp.
|
private |
Definition at line 115 of file ParameterMap.hpp.
| typedef SymTab<std::string, ParameterSharedPtr, true> torc::generic::ParameterMap::TabParams |
Definition at line 39 of file ParameterMap.hpp.
| typedef boost::shared_ptr<TabParams> torc::generic::ParameterMap::TabParamsPtr |
Definition at line 40 of file ParameterMap.hpp.
| torc::generic::ParameterMap::ParameterMap | ( | ) |
Definition at line 132 of file ParameterMap.cpp.
| torc::generic::ParameterMap::~ParameterMap | ( | ) | ||
| throw | ( | |||
| ) | ||||
Definition at line 134 of file ParameterMap.cpp.
| torc::generic::ParameterMap::ParameterMap | ( | const ParameterMap & | source | ) |
Definition at line 136 of file ParameterMap.cpp.
|
inline | ||||||||||||||||||||
Apply action on all parameters.
| [in] | inContext | the context for which the param is valid |
| [in] | action | Action to be applied |
Definition at line 120 of file ParameterMap.hpp.
Here is the call graph for this function:
|
inline | ||||||||||||||||||||
Apply action on overridden parameters
| [in] | inContext | the context for which the param is valid |
| [in] | action | Action to be applied |
Definition at line 140 of file ParameterMap.hpp.
Here is the call graph for this function:| ParameterSharedPtr torc::generic::ParameterMap::get | ( | const ParameterContext & | inContext, |
| const std::string & | inName | ||
| ) | const |
Get a named parameter or null if none exists
Definition at line 28 of file ParameterMap.cpp.
Here is the call graph for this function:| void torc::generic::ParameterMap::getAllParameters | ( | const ParameterContext & | inContext, |
| std::map< std::string, ParameterSharedPtr > & | outParams | ||
| ) | const |
Get all parameter name-value-pairs
| [in] | inContext | the context for which the param is valid |
| [out] | outParams | Map to be populated |
Definition at line 60 of file ParameterMap.cpp.
Here is the call graph for this function:| ParameterContext torc::generic::ParameterMap::getNewContext | ( | ) |
Definition at line 105 of file ParameterMap.cpp.
| void torc::generic::ParameterMap::getOverriddenParameters | ( | const ParameterContext & | inContext, |
| std::map< std::string, ParameterSharedPtr > & | outParams | ||
| ) | const |
Get all parameter name-value-pairs that have been overridden in this context. For a view context this will return an empty map.
| [in] | inContext | the context for which the param is valid |
| [out] | outParams | Map to be populated |
Definition at line 91 of file ParameterMap.cpp.
Here is the call graph for this function:| bool torc::generic::ParameterMap::isContextRegistered | ( | const ParameterContext & | inContext | ) | const |
Definition at line 122 of file ParameterMap.cpp.
Here is the call graph for this function:| ParameterMap & torc::generic::ParameterMap::operator= | ( | const ParameterMap & | source | ) |
Definition at line 139 of file ParameterMap.cpp.
| void torc::generic::ParameterMap::registerContext | ( | const ParameterContext & | inContext, |
| const ParameterContext & | inParentContext = ParameterContext() |
||
| ) | |||
| throw | ( | Error | |
| ) | |||
Definition at line 109 of file ParameterMap.cpp.
| void torc::generic::ParameterMap::set | ( | const ParameterContext & | inContext, |
| const std::string & | inName, | ||
| const ParameterSharedPtr & | inParam | ||
| ) |
Saves a parameter by name. Overrides existing parameters if it exists.
| [in] | inContext | the context for which the param is valid |
| [in] | inName | name of param |
| [in] | inParam | pointer to the parameter |
Definition at line 48 of file ParameterMap.cpp.
Here is the call graph for this function:| void torc::generic::ParameterMap::unregisterContext | ( | const ParameterContext & | inContext | ) |
Definition at line 128 of file ParameterMap.cpp.
Here is the call graph for this function:
|
private |
Definition at line 117 of file ParameterMap.hpp.
|
private |
Definition at line 116 of file ParameterMap.hpp.