diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-08-25 00:24:28 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-25 00:24:28 +0200 |
commit | 9d0b3d7aaa46b5b5fd4d998f7d9d70556eef41d6 (patch) | |
tree | 59195c62c3ca002c49bcf7b088bfad2aaf03be73 /core/io | |
parent | efedef8eb1ff931a046240091e4841cb886569ca (diff) | |
parent | 8c6b2fbb908261d29a6692dd7a816464c28520d2 (diff) |
Merge pull request #64844 from RandomShaper/fa_access_type
Add `FileAccess::get_access_type()`
Diffstat (limited to 'core/io')
-rw-r--r-- | core/io/file_access.cpp | 4 | ||||
-rw-r--r-- | core/io/file_access.h | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/core/io/file_access.cpp b/core/io/file_access.cpp index 8ed3d40c22..72c00bd678 100644 --- a/core/io/file_access.cpp +++ b/core/io/file_access.cpp @@ -115,6 +115,10 @@ FileAccess::CreateFunc FileAccess::get_create_func(AccessType p_access) { return create_func[p_access]; } +FileAccess::AccessType FileAccess::get_access_type() const { + return _access_type; +} + String FileAccess::fix_path(const String &p_path) const { //helper used by file accesses that use a single filesystem diff --git a/core/io/file_access.h b/core/io/file_access.h index 3386800686..fc0eb95d44 100644 --- a/core/io/file_access.h +++ b/core/io/file_access.h @@ -60,6 +60,7 @@ public: virtual Error _set_unix_permissions(const String &p_file, uint32_t p_permissions) = 0; protected: + AccessType get_access_type() const; String fix_path(const String &p_path) const; virtual Error _open(const String &p_path, int p_mode_flags) = 0; ///< open a file virtual uint64_t _get_modified_time(const String &p_file) = 0; |