summaryrefslogtreecommitdiff
path: root/core/src/Model
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/Model')
-rw-r--r--core/src/Model/Project.cpp15
-rw-r--r--core/src/Model/Project.hpp17
-rw-r--r--core/src/Model/fwd.hpp3
3 files changed, 35 insertions, 0 deletions
diff --git a/core/src/Model/Project.cpp b/core/src/Model/Project.cpp
new file mode 100644
index 0000000..f301bb8
--- /dev/null
+++ b/core/src/Model/Project.cpp
@@ -0,0 +1,15 @@
+#include "Project.hpp"
+
+#include <utility>
+
+const std::filesystem::path& Project::GetPath() const {
+ return mRootPath;
+}
+
+const std::string& Project::GetName() const {
+ return mName;
+}
+
+void Project::SetName(std::string name) {
+ mName = std::move(name);
+}
diff --git a/core/src/Model/Project.hpp b/core/src/Model/Project.hpp
new file mode 100644
index 0000000..34ae1d7
--- /dev/null
+++ b/core/src/Model/Project.hpp
@@ -0,0 +1,17 @@
+#pragma once
+
+#include <filesystem>
+#include <string>
+
+class Project {
+public:
+ std::filesystem::path mRootPath;
+ std::string mName;
+
+public:
+ // Path to a *directory* that contains the project file.
+ const std::filesystem::path& GetPath() const;
+
+ const std::string& GetName() const;
+ void SetName(std::string name);
+};
diff --git a/core/src/Model/fwd.hpp b/core/src/Model/fwd.hpp
index 6f70f09..f5a5818 100644
--- a/core/src/Model/fwd.hpp
+++ b/core/src/Model/fwd.hpp
@@ -1 +1,4 @@
#pragma once
+
+// Project.hpp
+class Project;