#include <plugin_manager.hpp>
|
|
typedef boost::function1< void, PluginType * > | PluginRunFunction |
| | data type for a function that may be called by the run() method
|
| |
|
typedef boost::function1< boost::uint64_t, const PluginType * > | PluginStatFunction |
| | data type for a function that may be called by the getStat() method
|
| |
|
|
| plugin_manager (void) |
| | default constructor
|
| |
|
virtual | ~plugin_manager () |
| | default destructor
|
| |
|
void | clear (void) |
| | clears all the plug-in objects being managed
|
| |
|
bool | empty (void) const |
| | returns true if there are no plug-in objects being managed
|
| |
| void | add (const std::string &plugin_id, PluginType *plugin_object_ptr) |
| |
| void | remove (const std::string &plugin_id) |
| |
| void | replace (const std::string &plugin_id, PluginType *plugin_ptr) |
| |
| PluginType * | clone (const std::string &plugin_id) |
| |
| PluginType * | load (const std::string &plugin_id, const std::string &plugin_type) |
| |
| PluginType * | get (const std::string &plugin_id) |
| |
| const PluginType * | get (const std::string &plugin_id) const |
| |
| plugin_ptr< PluginType > | get_lib_ptr (const std::string &plugin_id) const |
| |
| PluginType * | find (const std::string &resource) |
| |
| void | run (PluginRunFunction run_func) |
| |
| void | run (const std::string &plugin_id, PluginRunFunction run_func) |
| |
| boost::uint64_t | get_statistic (PluginStatFunction stat_func) const |
| |
| boost::uint64_t | get_statistic (const std::string &plugin_id, PluginStatFunction stat_func) const |
| |
template<typename PluginType>
class pion::plugin_manager< PluginType >
plugin_manager: used to manage a collection of plug-in objects
Definition at line 31 of file plugin_manager.hpp.
§ add()
template<typename PluginType>
| void pion::plugin_manager< PluginType >::add |
( |
const std::string & |
plugin_id, |
|
|
PluginType * |
plugin_object_ptr |
|
) |
| |
|
inline |
§ clone()
template<typename PluginType >
§ find()
template<typename PluginType >
§ get() [1/2]
template<typename PluginType >
gets the plug-in object associated with a particular plugin_id (exact match)
- Parameters
-
| plugin_id | unique identifier associated with the plug-in |
- Returns
- PluginType* pointer to the matching plug-in object or NULL if not found
Definition at line 262 of file plugin_manager.hpp.
§ get() [2/2]
template<typename PluginType >
gets the plug-in object associated with a particular plugin_id (exact match)
- Parameters
-
| plugin_id | unique identifier associated with the plug-in |
- Returns
- PluginType* pointer to the matching plug-in object or NULL if not found
Definition at line 273 of file plugin_manager.hpp.
§ get_lib_ptr()
template<typename PluginType >
§ get_statistic() [1/2]
template<typename PluginType >
§ get_statistic() [2/2]
template<typename PluginType >
returns a statistic value for a particular plug-in
- Parameters
-
| plugin_id | unique identifier associated with the plug-in |
| stat_func | the statistic function to execute |
Definition at line 372 of file plugin_manager.hpp.
§ load()
template<typename PluginType >
| PluginType * pion::plugin_manager< PluginType >::load |
( |
const std::string & |
plugin_id, |
|
|
const std::string & |
plugin_type |
|
) |
| |
|
inline |
§ remove()
template<typename PluginType >
removes a plug-in object
- Parameters
-
| plugin_id | unique identifier associated with the plug-in |
Definition at line 198 of file plugin_manager.hpp.
§ replace()
template<typename PluginType>
| void pion::plugin_manager< PluginType >::replace |
( |
const std::string & |
plugin_id, |
|
|
PluginType * |
plugin_ptr |
|
) |
| |
|
inline |
§ run() [1/2]
template<typename PluginType >
§ run() [2/2]
template<typename PluginType >
runs a method for a particular plug-in
- Parameters
-
| plugin_id | unique identifier associated with the plug-in |
| run_func | the function to execute |
Definition at line 348 of file plugin_manager.hpp.
The documentation for this class was generated from the following file: