aboutsummaryrefslogtreecommitdiff
path: root/core/src/Utils/IO/Archive.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/src/Utils/IO/Archive.hpp')
-rw-r--r--core/src/Utils/IO/Archive.hpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/core/src/Utils/IO/Archive.hpp b/core/src/Utils/IO/Archive.hpp
new file mode 100644
index 0000000..72f79c6
--- /dev/null
+++ b/core/src/Utils/IO/Archive.hpp
@@ -0,0 +1,22 @@
+#pragma once
+
+#include "Utils/IO/DataStream.hpp"
+
+#include <filesystem>
+#include <optional>
+
+class DataArchive
+{
+private:
+ DataStream mStream;
+
+public:
+ static std::optional<DataArchive> SaveFile(const std::filesystem::path& path);
+ static std::optional<DataArchive> LoadFile(const std::filesystem::path& path);
+
+ const DataStream& GetStream()const;
+ DataStream& GetStream();
+
+private:
+ DataArchive(DataStream stream);
+};