Panda3DS/include/fs/archive_system_save_data.hpp
2023-09-24 22:41:31 +03:00

28 lines
No EOL
975 B
C++

#pragma once
#include "archive_base.hpp"
class SystemSaveDataArchive : public ArchiveBase {
public:
SystemSaveDataArchive(Memory& mem) : ArchiveBase(mem) {}
u64 getFreeBytes() override {
Helpers::warn("Unimplemented GetFreeBytes for SystemSaveData archive");
return 32_MB;
}
std::string name() override { return "SystemSaveData"; }
HorizonResult createDirectory(const FSPath& path) override;
HorizonResult createFile(const FSPath& path, u64 size) override;
HorizonResult deleteFile(const FSPath& path) override;
Rust::Result<ArchiveBase*, HorizonResult> openArchive(const FSPath& path) override;
Rust::Result<DirectorySession, HorizonResult> openDirectory(const FSPath& path) override;
FileDescriptor openFile(const FSPath& path, const FilePerms& perms) override;
std::optional<u32> readFile(FileSession* file, u64 offset, u32 size, u32 dataPointer) override {
Helpers::panic("Unimplemented ReadFile for SystemSaveData archive");
return {};
};
};