break XML-parsing stuff into it's own files, and fix 'make test'
[reactos.git] / reactos / tools / rbuild / rbuild.h
index b99b6be..d50dcaa 100644 (file)
@@ -1,75 +1,11 @@
 #ifndef __RBUILD_H\r
 #define __RBUILD_H\r
 \r
+#include "XML.h"\r
+\r
 #include <string>\r
 #include <vector>\r
 \r
-class Path\r
-{\r
-       std::vector<std::string> path;\r
-public:\r
-       Path(); // initializes path to getcwd();\r
-       Path ( const Path& cwd, const std::string& filename );\r
-       std::string Fixup ( const std::string& filename, bool include_filename ) const;\r
-\r
-       static std::string RelativeFromWorkingDirectory ( const std::string& path );\r
-\r
-       static void Split ( std::vector<std::string>& out,\r
-                           const std::string& path,\r
-                           bool include_last );\r
-};\r
-\r
-class XMLFile\r
-{\r
-       friend class XMLElement;\r
-public:\r
-       XMLFile();\r
-       void close();\r
-       bool open(const std::string& filename);\r
-       void next_token();\r
-       bool next_is_text();\r
-       bool more_tokens();\r
-       bool get_token(std::string& token);\r
-\r
-private:\r
-       std::vector<FILE*> _f;\r
-       std::string _buf;\r
-\r
-       const char *_p, *_end;\r
-};\r
-\r
-\r
-class XMLAttribute\r
-{\r
-public:\r
-       std::string name;\r
-       std::string value;\r
-\r
-       XMLAttribute();\r
-       XMLAttribute ( const std::string& name_, const std::string& value_ );\r
-};\r
-\r
-\r
-class XMLElement\r
-{\r
-public:\r
-       std::string name;\r
-       std::vector<XMLAttribute*> attributes;\r
-       XMLElement* parentElement;\r
-       std::vector<XMLElement*> subElements;\r
-       std::string value;\r
-\r
-       XMLElement();\r
-       ~XMLElement();\r
-       bool Parse(const std::string& token,\r
-                  bool& end_tag);\r
-       void AddSubElement ( XMLElement* e );\r
-       XMLAttribute* GetAttribute ( const std::string& attribute,\r
-                                    bool required);\r
-       const XMLAttribute* GetAttribute ( const std::string& attribute,\r
-                                          bool required) const;\r
-};\r
-\r
 class Project;\r
 class Module;\r
 class File;\r