-public:
- Config_ModuleReader();
- virtual ~Config_ModuleReader();
-
- void setAutoImport(bool enabled);
- const std::map<std::string, std::string>& plugins() const;
-
- std::string getModuleName();
-
-protected:
- void processNode(xmlNodePtr aNode);
- bool processChildren(xmlNodePtr aNode);
-
- void importPlugin(const std::string& thePluginName,
- const std::string& thePluginLibrary = "");
-
-private:
- bool myIsAutoImport;
- std::map<std::string, std::string> myPluginsMap;
+ public:
+ /// Constructor
+ CONFIG_EXPORT Config_ModuleReader(const char* theEventGenerated = 0);
+ /// Destructor
+ CONFIG_EXPORT virtual ~Config_ModuleReader();
+ /// Returns map that describes which file contains a feature (the feature is key, the file is value)
+ CONFIG_EXPORT const std::map<std::string, std::string>& featuresInFiles() const;
+ /// Returns module name: an xml attribute from the root of the plugins.xml:
+ /// e.g \code <plugins module="PartSet"> \endcode
+ CONFIG_EXPORT std::string getModuleName();
+ /// Detects type of the given plugin and loads it using loadLibrary or loadScript.
+ CONFIG_EXPORT static void loadPlugin(const std::string& thePluginName);
+ /// loads the library with specific name, appends "lib*.dll" or "*.so" depending on the platform
+ CONFIG_EXPORT static void loadLibrary(const std::string& theLibName);
+ /// loads the python module with specified name
+ CONFIG_EXPORT static void loadScript(const std::string& theFileName);
+ /*!
+ * Extends set of modules, used for dependency checking (if there is no
+ * required module in the set, a plugin will not be loaded)
+ */
+ CONFIG_EXPORT static void addDependencyModule(const std::string& theModuleName);