aboutsummaryrefslogtreecommitdiff
path: root/src/core/file_sys/archive_extsavedata.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2015-02-10 18:27:16 -0500
committerbunnei <bunneidev@gmail.com>2015-02-10 18:27:16 -0500
commit27e6e6b3cb2ee1ab3a996c2b4be1d9a3c4e6b75d (patch)
treefd8b0290d4a0353c11c0e168200b20b5a89e297c /src/core/file_sys/archive_extsavedata.h
parent67db6aa4ce1f57f7d99406c8924ed41e74d36dbe (diff)
parent0d2b6dd6566b6718c806181c1f1c3bcdcede86ae (diff)
Merge pull request #540 from yuriks/multi-archives
FS: Allow multiple instances of the same archive type to be open at once
Diffstat (limited to 'src/core/file_sys/archive_extsavedata.h')
-rw-r--r--src/core/file_sys/archive_extsavedata.h21
1 files changed, 10 insertions, 11 deletions
diff --git a/src/core/file_sys/archive_extsavedata.h b/src/core/file_sys/archive_extsavedata.h
index 802a11b5f..83c6b0291 100644
--- a/src/core/file_sys/archive_extsavedata.h
+++ b/src/core/file_sys/archive_extsavedata.h
@@ -15,9 +15,9 @@
namespace FileSys {
/// File system interface to the ExtSaveData archive
-class Archive_ExtSaveData final : public DiskArchive {
+class ArchiveFactory_ExtSaveData final : public ArchiveFactory {
public:
- Archive_ExtSaveData(const std::string& mount_point, bool shared);
+ ArchiveFactory_ExtSaveData(const std::string& mount_point, bool shared);
/**
* Initialize the archive.
@@ -25,21 +25,20 @@ public:
*/
bool Initialize();
- ResultCode Open(const Path& path) override;
- ResultCode Format(const Path& path) const override;
std::string GetName() const override { return "ExtSaveData"; }
- const std::string& GetMountPoint() const override {
- return concrete_mount_point;
- }
+ ResultVal<std::unique_ptr<ArchiveBackend>> Open(const Path& path) override;
+ ResultCode Format(const Path& path) override;
-protected:
+ const std::string& GetMountPoint() const { return mount_point; }
+
+private:
/**
- * This holds the full directory path for this archive, it is only set after a successful call to Open,
- * this is formed as <base extsavedatapath>/<type>/<high>/<low>.
+ * This holds the full directory path for this archive, it is only set after a successful call
+ * to Open, this is formed as <base extsavedatapath>/<type>/<high>/<low>.
* See GetExtSaveDataPath for the code that extracts this data from an archive path.
*/
- std::string concrete_mount_point;
+ std::string mount_point;
};
/**