summaryrefslogtreecommitdiff
path: root/src/core/model/Project.cpp
diff options
context:
space:
mode:
authorAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-01-25 21:58:34 +0100
committerAndreas Stöckel <astoecke@techfak.uni-bielefeld.de>2015-01-25 21:58:34 +0100
commit4373ba6a600785db93b97afb5daa53dc14a17d19 (patch)
treeaa3694106889bcefc36833390b93f2a782d0e7bb /src/core/model/Project.cpp
parent15d1cfd2c5198be8e0105da269de3091568a7c6c (diff)
added parse, link and include functions to Project
Diffstat (limited to 'src/core/model/Project.cpp')
-rw-r--r--src/core/model/Project.cpp28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/core/model/Project.cpp b/src/core/model/Project.cpp
index a298ffc..1452de2 100644
--- a/src/core/model/Project.cpp
+++ b/src/core/model/Project.cpp
@@ -17,6 +17,8 @@
*/
#include <core/common/RttiBuilder.hpp>
+#include <core/parser/ParserScope.hpp>
+#include <core/parser/ParserContext.hpp>
#include "Domain.hpp"
#include "Document.hpp"
@@ -33,6 +35,32 @@ Project::Project(Manager &mgr, Registry &registry)
{
}
+Rooted<Node> Project::parse(const std::string &path, const std::string mimetype,
+ const std::string rel, RttiSet &supportedTypes,
+ Logger &logger)
+{
+ ParserScope scope;
+ ParserContext context(this, scope, logger);
+ return resourceManager.link(registry, context, path, mimetype, rel,
+ supportedTypes);
+}
+
+Rooted<Node> Project::link(ParserContext &ctx, const std::string &path,
+ const std::string mimetype, const std::string rel,
+ RttiSet &supportedTypes)
+{
+ return resourceManager.link(registry, ctx, path, mimetype, rel,
+ supportedTypes);
+}
+
+Rooted<Node> Project::include(ParserContext &ctx, const std::string &path,
+ const std::string mimetype, const std::string rel,
+ RttiSet &supportedTypes)
+{
+ return resourceManager.include(registry, ctx, path, mimetype, rel,
+ supportedTypes);
+}
+
bool Project::doValidate(Logger &logger) const
{
return continueValidation(documents, logger);