1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
6 * Created on: Mar 14, 2014
10 #ifndef CONFIG_XMLREADER_H_
11 #define CONFIG_XMLREADER_H_
13 #include <Config_def.h>
18 //>> Forward declaration of xmlNodePtr.
19 typedef struct _xmlNode xmlNode;
20 typedef xmlNode *xmlNodePtr;
24 //>> Forward declaration of xmlDocPtr.
25 typedef struct _xmlDoc xmlDoc;
26 typedef xmlDoc *xmlDocPtr;
31 * Base class for all libxml readers. Provides high-level API
32 * for all xml operations.
35 class Config_XMLReader
38 CONFIG_EXPORT Config_XMLReader(const std::string& theXmlFile);CONFIG_EXPORT virtual ~Config_XMLReader();
40 CONFIG_EXPORT void readAll();
43 CONFIG_EXPORT xmlNodePtr findRoot();
46 virtual void processNode(xmlNodePtr aNode);
47 virtual bool processChildren(xmlNodePtr aNode);
49 void readRecursively(xmlNodePtr theParent);
51 xmlNodePtr node(void* theNode);
52 std::string getNodeName(xmlNodePtr theNode);
53 void processValidator(xmlNodePtr theNode);
54 void processSelectionFilter(xmlNodePtr theNode);
57 std::string myCurrentFeature;
60 std::string myDocumentPath;
64 #endif /* CONFIG_XMLREADER_H_ */