Salome HOME
Merge branch 'Dev_0.6.1' of newgeom:newgeom into Dev_0.6.1
[modules/shaper.git] / src / Config / Config_ModuleReader.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 /*
4  * Config_XMLModuleReader.h
5  *
6  *  Created on: Mar 20, 2014
7  *      Author: sbh
8  */
9
10 #ifndef CONFIG_MODULEREADER_H_
11 #define CONFIG_MODULEREADER_H_
12
13 #include <Config_def.h>
14 #include <Config_XMLReader.h>
15
16 #include <map>
17 #include <list>
18 #include <string>
19
20 class Config_ModuleReader : public Config_XMLReader
21 {
22
23  public:
24   CONFIG_EXPORT Config_ModuleReader(const char* theEventGenerated = 0);
25   CONFIG_EXPORT virtual ~Config_ModuleReader();
26
27   CONFIG_EXPORT const std::map<std::string, std::string>& featuresInFiles() const;
28
29   CONFIG_EXPORT std::string getModuleName();
30
31   /// loads the library with specific name, appends "lib*.dll" or "*.so" depending on the platform
32   CONFIG_EXPORT static void loadLibrary(const std::string theLibName);
33
34  protected:
35   void processNode(xmlNodePtr aNode);
36   bool processChildren(xmlNodePtr aNode);
37
38   std::list<std::string> importPlugin(const std::string& thePluginLibrary,
39                                       const std::string& thePluginFile);
40
41  private:
42   std::map<std::string, std::string> myFeaturesInFiles;
43   const char* myEventGenerated;
44
45 };
46
47 #endif /* CONFIG_XMLMODULEREADER_H_ */