rename some of the classes

CParser is now just parser. CTree is now Schema. The namespace "schema" is
now called "yang".

Change-Id: Ief9c22fb6a7633b80010d355f9582e313e818d45
diff --git a/src/parser.hpp b/src/parser.hpp
new file mode 100644
index 0000000..feb7911
--- /dev/null
+++ b/src/parser.hpp
@@ -0,0 +1,45 @@
+/*
+ * Copyright (C) 2018 CESNET, https://photonics.cesnet.cz/
+ * Copyright (C) 2018 FIT CVUT, https://fit.cvut.cz/
+ *
+ * Written by Václav Kubernát <kubervac@fit.cvut.cz>
+ *
+*/
+
+#pragma once
+#include <boost/spirit/home/x3.hpp>
+#include "grammars.hpp"
+namespace x3 = boost::spirit::x3;
+namespace ascii = boost::spirit::x3::ascii;
+using Cmd = std::vector<std::string>;
+using ascii::space;
+using x3::_attr;
+using x3::alpha;
+using x3::char_;
+using x3::lexeme;
+using x3::lit;
+
+class InvalidCommandException : public std::invalid_argument {
+public:
+    using std::invalid_argument::invalid_argument;
+    ~InvalidCommandException() override;
+};
+
+class TooManyArgumentsException : public std::invalid_argument {
+public:
+    using std::invalid_argument::invalid_argument;
+    ~TooManyArgumentsException() override;
+};
+
+
+class Parser {
+public:
+    Parser(const Schema& schema);
+    cd_ parseCommand(const std::string& line, std::ostream& errorStream);
+    void changeNode(const path_& name);
+    std::string currentNode() const;
+
+private:
+    const Schema& m_schema;
+    path_ m_curDir;
+};