mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 06:39:46 -06:00
DiscIO: Use std::string_view in FileSystem::FindFileInfo
...and in the functions that call it.
This commit is contained in:
@ -9,6 +9,7 @@
|
||||
#include <memory>
|
||||
#include <optional>
|
||||
#include <string>
|
||||
#include <string_view>
|
||||
#include <vector>
|
||||
|
||||
#include "Common/CommonTypes.h"
|
||||
@ -90,7 +91,7 @@ public:
|
||||
|
||||
bool IsValid() const override { return m_valid; }
|
||||
const FileInfo& GetRoot() const override;
|
||||
std::unique_ptr<FileInfo> FindFileInfo(const std::string& path) const override;
|
||||
std::unique_ptr<FileInfo> FindFileInfo(std::string_view path) const override;
|
||||
std::unique_ptr<FileInfo> FindFileInfo(u64 disc_offset) const override;
|
||||
|
||||
private:
|
||||
@ -100,7 +101,7 @@ private:
|
||||
// Maps the end offset of files to FST indexes
|
||||
mutable std::map<u64, u32> m_offset_file_info_cache;
|
||||
|
||||
std::unique_ptr<FileInfo> FindFileInfo(const std::string& path, const FileInfo& file_info) const;
|
||||
std::unique_ptr<FileInfo> FindFileInfo(std::string_view path, const FileInfo& file_info) const;
|
||||
};
|
||||
|
||||
} // namespace DiscIO
|
||||
|
Reference in New Issue
Block a user