X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FConfig%2FConfig_ModuleReader.h;h=2281eb5cd33910e46bd16949e25b8b8b7afe6f7e;hb=031fb5e7c551e695afa72a9de299f118a40d8d88;hp=18962f3488b9dbc03f7c41173fa143052e43946b;hpb=8dc74f82810d5f597b78633b457efb0ef4f89f9f;p=modules%2Fshaper.git diff --git a/src/Config/Config_ModuleReader.h b/src/Config/Config_ModuleReader.h index 18962f348..2281eb5cd 100644 --- a/src/Config/Config_ModuleReader.h +++ b/src/Config/Config_ModuleReader.h @@ -1,3 +1,5 @@ +// Copyright (C) 2014-20xx CEA/DEN, EDF R&D + /* * Config_XMLModuleReader.h * @@ -17,16 +19,25 @@ class Config_ModuleReader : public Config_XMLReader { + enum PluginType { + Binary = 0, + Intrenal = 1, + Python = 2 + }; public: - CONFIG_EXPORT Config_ModuleReader(const char* theEventGenerated = 0);CONFIG_EXPORT virtual ~Config_ModuleReader(); + CONFIG_EXPORT Config_ModuleReader(const char* theEventGenerated = 0); + CONFIG_EXPORT virtual ~Config_ModuleReader(); CONFIG_EXPORT const std::map& featuresInFiles() const; CONFIG_EXPORT std::string getModuleName(); + 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); protected: void processNode(xmlNodePtr aNode); @@ -34,9 +45,13 @@ class Config_ModuleReader : public Config_XMLReader std::list importPlugin(const std::string& thePluginLibrary, const std::string& thePluginFile); + std::string addPlugin(const std::string& aPluginLibrary, + const std::string& aPluginScript, + const std::string& aPluginConf); private: std::map myFeaturesInFiles; + static std::map myPluginTypes; const char* myEventGenerated; };