39 #ifndef MBF_ABSTRACT_NAV__ABSTRACT_PLUGIN_MANAGER_H_ 40 #define MBF_ABSTRACT_NAV__ABSTRACT_PLUGIN_MANAGER_H_ 42 #include <boost/function.hpp> 47 template <
typename PluginType>
53 typedef boost::function<bool (const std::string &name, const typename PluginType::Ptr &plugin_ptr)>
initPluginFunction;
56 const std::string ¶m_name,
57 const loadPluginFunction &loadPlugin,
58 const initPluginFunction &initPlugin
65 std::string
getType(
const std::string &name);
69 typename PluginType::Ptr
getPlugin(
const std::string &name);
74 std::map<std::string, typename PluginType::Ptr>
plugins_;
84 #include "impl/abstract_plugin_manager.tcc" PluginType::Ptr getPlugin(const std::string &name)
const std::string param_name_
const initPluginFunction initPlugin_
std::map< std::string, typename PluginType::Ptr > plugins_
std::map< std::string, std::string > plugins_type_
boost::function< typename PluginType::Ptr(const std::string &plugin)> loadPluginFunction
const std::vector< std::string > & getLoadedNames()
boost::function< bool(const std::string &name, const typename PluginType::Ptr &plugin_ptr)> initPluginFunction
AbstractPluginManager(const std::string ¶m_name, const loadPluginFunction &loadPlugin, const initPluginFunction &initPlugin)
bool hasPlugin(const std::string &name)
const loadPluginFunction loadPlugin_
std::vector< std::string > names_
std::string getType(const std::string &name)