26 #ifndef INCLUDED_RegistrationContext_h_GUID_9FF83E64_B2E1_40B7_E072_929AC0F94A10 27 #define INCLUDED_RegistrationContext_h_GUID_9FF83E64_B2E1_40B7_E072_929AC0F94A10 35 #include <osvr/PluginHost/Export.h> 39 #include <boost/noncopyable.hpp> 49 namespace pluginhost {
65 OSVR_PLUGINHOST_EXPORT
void loadPlugin(std::string
const &pluginName);
73 OSVR_PLUGINHOST_EXPORT
void 84 OSVR_PLUGINHOST_EXPORT
void 86 const std::string &driverName,
87 const std::string ¶ms = std::string())
const;
99 typedef std::map<std::string, PluginRegPtr> PluginRegMap;
101 PluginRegMap m_regMap;
105 unique_ptr<Impl> m_impl;
106 util::log::LoggerPtr m_logger;
111 #endif // INCLUDED_RegistrationContext_h_GUID_9FF83E64_B2E1_40B7_E072_929AC0F94A10 OSVR_PLUGINHOST_EXPORT RegistrationContext()
basic constructor
Definition: RegistrationContext.cpp:66
Class responsible for hosting plugins, along with their registration and destruction.
Definition: RegistrationContext.h:53
OSVR_PLUGINHOST_EXPORT void loadPlugins()
Load all detected plugins except those with a .manualload suffix.
Definition: RegistrationContext.cpp:158
The main namespace for all C++ elements of the framework, internal and external.
Definition: namespace_osvr.dox:3
Header to bring unique_ptr into the osvr namespace.
Header for basic internal log reference.
Header to bring shared_ptr into the osvr namespace.
OSVR_PLUGINHOST_EXPORT ~RegistrationContext()
Destructor responsible for destroying plugins in reverse order.
Definition: RegistrationContext.cpp:70
A data structure storing "any" by name, to reduce coupling.
Definition: AnyMap.h:42
Definition: RegistrationContext.cpp:59
OSVR_PLUGINHOST_EXPORT void adoptPluginRegistrationContext(PluginRegPtr ctx)
Assume ownership of a plugin-specific registration context created and initialized outside of loadPlu...
Definition: RegistrationContext.cpp:210
OSVR_PLUGINHOST_EXPORT util::AnyMap & data()
Access the data storage map.
Definition: RegistrationContext.cpp:236
Header declaring the osvr::util::AnyMap structure.
OSVR_PLUGINHOST_EXPORT void triggerHardwareDetect()
Trigger any registered hardware detect callbacks.
Definition: RegistrationContext.cpp:218
shared_ptr< PluginSpecificRegistrationContextImpl > PluginRegPtr
Pointer with ownership semantics for cleanup of plugins.
Definition: PluginRegPtr.h:33
OSVR_PLUGINHOST_EXPORT void instantiateDriver(const std::string &pluginName, const std::string &driverName, const std::string ¶ms=std::string()) const
Call a driver instantiation callback for the given plugin name and driver name.
Definition: RegistrationContext.cpp:225
Header forward-declaring RegistrationContext.