|
CeresEngine 0.2.0
A game development framework
|
File handle for the local file system on Windows. More...
#include <CeresEngine/Platform/Win32/Win32FileHandle.hpp>
Public Member Functions | |
| Win32FileHandle (Win32FileSystem &fs, StringView path) | |
| Constructs a new Win32 File Handle. | |
| Win32FileHandle (const Win32FileHandle &other) | |
| ~Win32FileHandle () final | |
| void | updateFileInfo () final |
| Update file information. | |
| Int64 | getAccessTime () const final |
| Gets the time of last access. | |
| Int64 | getModificationTime () const final |
| Gets time of last modification. | |
Public Member Functions inherited from CeresEngine::LocalFileHandle | |
| LocalFileHandle (LocalFileSystem &fileSystem, StringView path) | |
| LocalFileHandle (LocalFileSystem &fileSystem, String &&path) | |
| ~LocalFileHandle () override | |
| IFileSystem * | getFileSystem () const override |
Gets the backing IFileSystem for the handle. | |
| StringView | getPath () const override |
| bool | exists () const override |
| Checks if the file exists on the file system. | |
| bool | isFile () const override |
| Checks if item is a file. | |
| bool | isDirectory () const override |
| Checks if item is a directory. | |
| bool | isSymbolicLink () const override |
| Checks if item is a symbolic link. | |
| FileIterator | begin () const override |
| Gets an iterator that points to the first directory entry. | |
| UInt64 | getSize () const override |
| Gets the file size. | |
| bool | createDirectory () override |
| Creates a new directory. | |
| bool | removeDirectory () override |
| Removes a directory. | |
| bool | copy (IFileHandle &dest) override |
| Copies a file. | |
| bool | move (IFileHandle &dest) override |
| Moves a file. | |
| bool | createLink (IFileHandle &dest) override |
| Creates a hard link. | |
| bool | createSymbolicLink (IFileHandle &dest) override |
| Creates a symbolic link. | |
| bool | rename (StringView filename) override |
| Renames a file or directory. | |
| bool | remove () override |
| Removes a file. | |
| InputStream | createInputStream (std::ios_base::openmode mode) const override |
| Creates an input stream to read from the file. | |
| OutputStream | createOutputStream (std::ios_base::openmode mode) override |
| Creates an output stream to write to the file. | |
Public Member Functions inherited from CeresEngine::IFileHandle | |
| IFileHandle ()=default | |
| virtual | ~IFileHandle ()=default |
Protected Member Functions | |
| void | readFileInfo () const |
Private Types | |
| using | super = LocalFileHandle |
Private Attributes | |
| UPtr< void, void(*)(void *)> | mFileInfo |
| Information about the current file (created on demand) | |
Additional Inherited Members | |
Protected Attributes inherited from CeresEngine::LocalFileHandle | |
| RC< LocalFileSystem > | mFileSystem |
| The file system that created this handle. | |
| FilePath | mPath |
| Path to file or directory. | |
| std::filesystem::path | mFileSystemPath |
Same as mPath, but in the C++17 std::filesystem format. | |
File handle for the local file system on Windows.
| CeresEngine::Win32FileHandle::Win32FileHandle | ( | Win32FileSystem & | fs, |
| StringView | path | ||
| ) |
Constructs a new Win32 File Handle.
| fs | The file system that created this handle. |
| path | The path to file or directory. |
| CeresEngine::Win32FileHandle::Win32FileHandle | ( | const Win32FileHandle & | other | ) |
|
final |
|
finalvirtual |
Gets the time of last access.
Reimplemented from CeresEngine::LocalFileHandle.
|
finalvirtual |
Gets time of last modification.
Reimplemented from CeresEngine::LocalFileHandle.
|
protected |
|
finalvirtual |
Update file information.
Must reload and update the file information. It will for example be called after a file has been created, copied, or removed to ensure that the file information returned by the handle is correct.
Reimplemented from CeresEngine::LocalFileHandle.
Information about the current file (created on demand)