LeviLamina
Loading...
Searching...
No Matches
FileSystem_windows.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/file/DirectoryIterationFlags.h"
7#include "mc/deps/core/file/FileAccessType.h"
8#include "mc/deps/core/file/FileBufferingMode.h"
9#include "mc/deps/core/file/FileType.h"
10#include "mc/deps/core/file/file_system/FileSystemImpl.h"
11#include "mc/platform/brstd/function_ref.h"
12
13// auto generated forward declare list
14// clang-format off
15namespace Core { class FileImpl; }
16namespace Core { class FileOpenMode; }
17namespace Core { class FileStorageArea; }
18namespace Core { class FlatFileManifestTracker; }
19namespace Core { class PathView; }
20namespace Core { class Result; }
21namespace Core { struct DirectoryIterationItem; }
22// clang-format on
23
24namespace Core {
25
27public:
28 // prevent constructor by default
30
31public:
32 // virtual functions
33 // NOLINTBEGIN
34 // vIndex: 7
35 virtual ::Core::Result _openFile(
36 ::std::unique_ptr<::Core::FileImpl>& uptFileOut,
37 ::Core::PathView filename,
38 ::Core::FileOpenMode fileOpenMode,
39 ::Core::FileBufferingMode bufferingMode
40 ) /*override*/;
41
42 // vIndex: 8
43 virtual bool _fileExists(::Core::PathView filePath) /*override*/;
44
45 // vIndex: 9
46 virtual ::Core::Result _deleteFile(::Core::PathView path) /*override*/;
47
48 // vIndex: 11
49 virtual ::Core::Result _getFileSize(::Core::PathView filePath, uint64* pFileSizeOut) /*override*/;
50
51 // vIndex: 12
52 virtual ::Core::Result _renameFile(::Core::PathView sourceFilePath, ::Core::PathView targetFilePath) /*override*/;
53
54 // vIndex: 17
55 virtual ::Core::Result _createOneDirectory(::Core::PathView directoryPath) /*override*/;
56
57 // vIndex: 21
58 virtual ::Core::Result _deleteEmptyDirectory(::Core::PathView directoryPath) /*override*/;
59
60 // vIndex: 20
61 virtual bool _directoryExists(::Core::PathView directoryPath) /*override*/;
62
63 // vIndex: 25
64 virtual ::Core::Result
65 _renameDirectory(::Core::PathView sourceDirectoryPath, ::Core::PathView targetDirectoryPath) /*override*/;
66
67 // vIndex: 26
68 virtual ::Core::Result _iterateOverDirectory(
69 ::Core::PathView directoryPath,
70 ::Core::DirectoryIterationFlags flags,
72 ) /*override*/;
73
74 // vIndex: 32
75 virtual bool _fileOrDirectoryExists(::Core::PathView entryPath) /*override*/;
76
77 // vIndex: 45
78 virtual ::Core::Result _getLastModificationTime(::Core::PathView filePath, int64* pModificationTime) /*override*/;
79
80 // vIndex: 34
81 virtual ::Core::Result _getEntryType(::Core::PathView entryPath, ::Core::FileType& fileTypeOut) /*override*/;
82
83 // vIndex: 46
84 virtual ::Core::Result
85 _copyTimeAndAccessRights(::Core::PathView sourceEntryPath, ::Core::PathView targetEntryPath) /*override*/;
86
87 // vIndex: 3
88 virtual void requestFlush() /*override*/;
89
90 // vIndex: 0
91 virtual ~FileSystem_windows() /*override*/ = default;
92 // NOLINTEND
93
94public:
95 // member functions
96 // NOLINTBEGIN
98 ::Core::FileAccessType accessType,
99 ::std::shared_ptr<::Core::FileStorageArea> storageArea,
100 ::std::shared_ptr<::Core::FlatFileManifestTracker> manifestTracker
101 );
102
103 MCNAPI ::Core::Result _iterateOverDirectoryWide(
104 ::std::wstring const& directoryPath,
105 ::Core::DirectoryIterationFlags flags,
107 );
108
109 MCNAPI ::Core::Result
110 _makeFailureFromFileSystemResult(::std::error_code const& errorCode, char const* function, char const* fileContext);
111 // NOLINTEND
112
113public:
114 // constructor thunks
115 // NOLINTBEGIN
116 MCNAPI void* $ctor(
117 ::Core::FileAccessType accessType,
118 ::std::shared_ptr<::Core::FileStorageArea> storageArea,
119 ::std::shared_ptr<::Core::FlatFileManifestTracker> manifestTracker
120 );
121 // NOLINTEND
122
123public:
124 // virtual function thunks
125 // NOLINTBEGIN
126 MCNAPI ::Core::Result $_openFile(
127 ::std::unique_ptr<::Core::FileImpl>& uptFileOut,
128 ::Core::PathView filename,
129 ::Core::FileOpenMode fileOpenMode,
130 ::Core::FileBufferingMode bufferingMode
131 );
132
133 MCNAPI bool $_fileExists(::Core::PathView filePath);
134
135 MCNAPI ::Core::Result $_deleteFile(::Core::PathView path);
136
137 MCNAPI ::Core::Result $_getFileSize(::Core::PathView filePath, uint64* pFileSizeOut);
138
139 MCNAPI ::Core::Result $_renameFile(::Core::PathView sourceFilePath, ::Core::PathView targetFilePath);
140
141 MCNAPI ::Core::Result $_createOneDirectory(::Core::PathView directoryPath);
142
143 MCNAPI ::Core::Result $_deleteEmptyDirectory(::Core::PathView directoryPath);
144
145 MCNAPI bool $_directoryExists(::Core::PathView directoryPath);
146
147 MCNAPI ::Core::Result $_renameDirectory(::Core::PathView sourceDirectoryPath, ::Core::PathView targetDirectoryPath);
148
149 MCNAPI ::Core::Result $_iterateOverDirectory(
150 ::Core::PathView directoryPath,
151 ::Core::DirectoryIterationFlags flags,
153 );
154
156
157 MCNAPI ::Core::Result $_getLastModificationTime(::Core::PathView filePath, int64* pModificationTime);
158
159 MCNAPI ::Core::Result $_getEntryType(::Core::PathView entryPath, ::Core::FileType& fileTypeOut);
160
161 MCNAPI ::Core::Result $_copyTimeAndAccessRights(::Core::PathView sourceEntryPath, ::Core::PathView targetEntryPath);
162
163 MCNAPI void $requestFlush();
164 // NOLINTEND
165
166public:
167 // vftables
168 // NOLINTBEGIN
169 MCNAPI static void** $vftable();
170 // NOLINTEND
171};
172
173} // namespace Core
Definition FileOpenMode.h:7
Definition FileSystemImpl.h:30
Definition FileSystem_windows.h:26
MCAPI::Core::Result $_deleteFile(::Core::PathView path)
MCAPI::Core::Result _makeFailureFromFileSystemResult(::std::error_code const &errorCode, char const *function, char const *fileContext)
MCAPI void * $ctor(::Core::FileAccessType accessType, ::std::shared_ptr<::Core::FileStorageArea > storageArea, ::std::shared_ptr<::Core::FlatFileManifestTracker > manifestTracker)
MCAPI bool $_directoryExists(::Core::PathView directoryPath)
MCAPI::Core::Result $_openFile(::std::unique_ptr<::Core::FileImpl > &uptFileOut, ::Core::PathView filename, ::Core::FileOpenMode fileOpenMode, ::Core::FileBufferingMode bufferingMode)
MCAPI void $requestFlush()
MCAPI::Core::Result $_getLastModificationTime(::Core::PathView filePath, int64 *pModificationTime)
MCAPI::Core::Result $_deleteEmptyDirectory(::Core::PathView directoryPath)
MCAPI::Core::Result $_renameDirectory(::Core::PathView sourceDirectoryPath, ::Core::PathView targetDirectoryPath)
MCAPI::Core::Result $_getEntryType(::Core::PathView entryPath, ::Core::FileType &fileTypeOut)
MCAPI bool $_fileOrDirectoryExists(::Core::PathView entryPath)
MCAPI::Core::Result $_getFileSize(::Core::PathView filePath, uint64 *pFileSizeOut)
MCAPI bool $_fileExists(::Core::PathView filePath)
MCAPI::Core::Result _iterateOverDirectoryWide(::std::wstring const &directoryPath, ::Core::DirectoryIterationFlags flags, ::brstd::function_ref<::Core::Result(::Core::DirectoryIterationItem const &)> fx)
static MCAPI void ** $vftable()
MCAPI::Core::Result $_createOneDirectory(::Core::PathView directoryPath)
MCAPI FileSystem_windows(::Core::FileAccessType accessType, ::std::shared_ptr<::Core::FileStorageArea > storageArea, ::std::shared_ptr<::Core::FlatFileManifestTracker > manifestTracker)
MCAPI::Core::Result $_copyTimeAndAccessRights(::Core::PathView sourceEntryPath, ::Core::PathView targetEntryPath)
MCAPI::Core::Result $_iterateOverDirectory(::Core::PathView directoryPath, ::Core::DirectoryIterationFlags flags, ::brstd::function_ref<::Core::Result(::Core::DirectoryIterationItem const &)> fx)
MCAPI::Core::Result $_renameFile(::Core::PathView sourceFilePath, ::Core::PathView targetFilePath)
Definition PathView.h:15
Definition Result.h:11
Definition function_ref.h:60
Definition DirectoryIterationItem.h:12