[FS] Formatting archives v1

This commit is contained in:
wheremyfoodat 2023-05-16 23:37:52 +03:00
parent 2f5bb45d58
commit 4dc04be350
6 changed files with 67 additions and 4 deletions

View file

@ -224,6 +224,10 @@ public:
return Err(FSResult::FileNotFound);
}
virtual void format(const FSPath& path, const FormatInfo& info) {
Helpers::panic("Unimplemented Format for %s archive", name().c_str());
}
// Read size bytes from a file starting at offset "offset" into a certain buffer in memory
// Returns the number of bytes read, or nullopt if the read failed
virtual std::optional<u32> readFile(FileSession* file, u64 offset, u32 size, u32 dataPointer) = 0;