diff options
author | Lioncash <mathew1800@gmail.com> | 2018-07-22 07:23:29 +0200 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2018-07-22 09:22:21 +0200 |
commit | 398444e67635c158a20301d1a32a1c45bfdd4056 (patch) | |
tree | db638ebe09199ae64b69f5911136effa9756571f /src/core/file_sys/vfs_real.h | |
parent | Merge pull request #764 from lioncash/move (diff) | |
download | yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar.gz yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar.bz2 yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar.lz yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar.xz yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.tar.zst yuzu-398444e67635c158a20301d1a32a1c45bfdd4056.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/file_sys/vfs_real.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/core/file_sys/vfs_real.h b/src/core/file_sys/vfs_real.h index 5b765a552..2151211c9 100644 --- a/src/core/file_sys/vfs_real.h +++ b/src/core/file_sys/vfs_real.h @@ -4,6 +4,8 @@ #pragma once +#include <string_view> + #include "common/file_util.h" #include "core/file_sys/mode.h" #include "core/file_sys/vfs.h" @@ -24,7 +26,7 @@ struct RealVfsFile : public VfsFile { bool IsReadable() const override; size_t Read(u8* data, size_t length, size_t offset) const override; size_t Write(const u8* data, size_t length, size_t offset) override; - bool Rename(const std::string& name) override; + bool Rename(std::string_view name) override; private: bool Close(); @@ -47,11 +49,11 @@ struct RealVfsDirectory : public VfsDirectory { bool IsReadable() const override; std::string GetName() const override; std::shared_ptr<VfsDirectory> GetParentDirectory() const override; - std::shared_ptr<VfsDirectory> CreateSubdirectory(const std::string& name) override; - std::shared_ptr<VfsFile> CreateFile(const std::string& name) override; - bool DeleteSubdirectory(const std::string& name) override; - bool DeleteFile(const std::string& name) override; - bool Rename(const std::string& name) override; + std::shared_ptr<VfsDirectory> CreateSubdirectory(std::string_view name) override; + std::shared_ptr<VfsFile> CreateFile(std::string_view name) override; + bool DeleteSubdirectory(std::string_view name) override; + bool DeleteFile(std::string_view name) override; + bool Rename(std::string_view name) override; protected: bool ReplaceFileWithSubdirectory(VirtualFile file, VirtualDir dir) override; |