engine
 
载入中...
搜索中...
未找到
Public 成员函数 | 静态 Public 成员函数 | 所有成员列表
FFileManagerGeneric类 参考

Base class for file managers. 更多...

#include <FileManagerGeneric.h>

继承自 IFileManager .

Public 成员函数

FString ConvertToAbsolutePathForExternalAppForRead (const TCHAR *Filename) override
 Converts passed in filename to use an absolute path (for reading) 更多...
 
FString ConvertToAbsolutePathForExternalAppForWrite (const TCHAR *Filename) override
 Converts passed in filename to use an absolute path (for writing) 更多...
 
FString ConvertToRelativePath (const TCHAR *Filename) override
 Converts passed in filename to use a relative path. 更多...
 
 FFileManagerGeneric ()
 Default constructor.
 
int64 FileSize (const TCHAR *Filename) override
 Returns the size of a file. 更多...
 
virtual void FindFiles (TArray< FString > &FoundFiles, const TCHAR *Directory, const TCHAR *FileExtension=nullptr) override
 Finds all the files within the given directory, with optional file extension filter. 更多...
 
bool IterateDirectory (const TCHAR *Directory, IPlatformFile::FDirectoryVisitor &Visitor) override
 Call the Visit function of the visitor once for each file or directory in a single directory. 更多...
 
bool IterateDirectoryRecursively (const TCHAR *Directory, IPlatformFile::FDirectoryVisitor &Visitor) override
 Call the Visit function of the visitor once for each file or directory in a directory tree. 更多...
 
bool IterateDirectoryStat (const TCHAR *Directory, IPlatformFile::FDirectoryStatVisitor &Visitor) override
 Call the Visit function of the visitor once for each file or directory in a single directory. 更多...
 
bool IterateDirectoryStatRecursively (const TCHAR *Directory, IPlatformFile::FDirectoryStatVisitor &Visitor) override
 Call the Visit function of the visitor once for each file or directory in a directory tree. 更多...
 
virtual bool SendMessageToServer (const TCHAR *Message, IPlatformFile::IFileServerMessageHandler *Handler) override
 Sends a message to the file server, and will block until it's complete. 更多...
 
virtual ~FFileManagerGeneric ()
 Virtual destructor.
 

静态 Public 成员函数

static FString DefaultConvertToRelativePath (const TCHAR *Filename)
 Converts passed in filename to use a relative path. 更多...
 

详细描述

Base class for file managers.

This base class simplifies IFileManager implementations by providing simple, unoptimized implementations of functions whose implementations can be derived from other functions.

成员函数说明

◆ ConvertToAbsolutePathForExternalAppForRead()

FString FFileManagerGeneric::ConvertToAbsolutePathForExternalAppForRead ( const TCHAR *  Filename)
override

Converts passed in filename to use an absolute path (for reading)

参数
Filenamefilename to convert to use an absolute path, safe to pass in already using absolute path
返回
filename using absolute path

◆ ConvertToAbsolutePathForExternalAppForWrite()

FString FFileManagerGeneric::ConvertToAbsolutePathForExternalAppForWrite ( const TCHAR *  Filename)
override

Converts passed in filename to use an absolute path (for writing)

参数
Filenamefilename to convert to use an absolute path, safe to pass in already using absolute path
返回
filename using absolute path

◆ ConvertToRelativePath()

FString FFileManagerGeneric::ConvertToRelativePath ( const TCHAR *  Filename)
override

Converts passed in filename to use a relative path.

参数
Filenamefilename to convert to use a relative path
返回
filename using relative path

◆ DefaultConvertToRelativePath()

static FString FFileManagerGeneric::DefaultConvertToRelativePath ( const TCHAR *  Filename)
static

Converts passed in filename to use a relative path.

参数
Filenamefilename to convert to use a relative path
返回
filename using relative path

◆ FileSize()

int64 FFileManagerGeneric::FileSize ( const TCHAR *  Filename)
override

Returns the size of a file.

(Thread-safe)

参数
FilenamePlatform-independent Unreal filename.
返回
File size in bytes or INDEX_NONE if the file didn't exist.

◆ FindFiles()

virtual void FFileManagerGeneric::FindFiles ( TArray< FString > &  FoundFiles,
const TCHAR *  Directory,
const TCHAR *  FileExtension = nullptr 
)
overridevirtual

Finds all the files within the given directory, with optional file extension filter.

参数
Directory,theabsolute path to the directory to search. Ex: "C:\UE4\Pictures"
FileExtension,IfFileExtension is NULL, or an empty string "" then all files are found. Otherwise FileExtension can be of the form .EXT or just EXT and only files with that extension will be returned.
返回
FoundFiles, All the files that matched the optional FileExtension filter, or all files if none was specified.

◆ IterateDirectory()

bool FFileManagerGeneric::IterateDirectory ( const TCHAR *  Directory,
IPlatformFile::FDirectoryVisitor &  Visitor 
)
override

Call the Visit function of the visitor once for each file or directory in a single directory.

This function does not explore subdirectories.

参数
DirectoryThe directory to iterate the contents of.
VisitorVisitor to call for each element of the directory
返回
false if the directory did not exist or if the visitor returned false.

◆ IterateDirectoryRecursively()

bool FFileManagerGeneric::IterateDirectoryRecursively ( const TCHAR *  Directory,
IPlatformFile::FDirectoryVisitor &  Visitor 
)
override

Call the Visit function of the visitor once for each file or directory in a directory tree.

This function explores subdirectories.

参数
DirectoryThe directory to iterate the contents of, recursively.
VisitorVisitor to call for each element of the directory and each element of all subdirectories.
返回
false if the directory did not exist or if the visitor returned false.

◆ IterateDirectoryStat()

bool FFileManagerGeneric::IterateDirectoryStat ( const TCHAR *  Directory,
IPlatformFile::FDirectoryStatVisitor &  Visitor 
)
override

Call the Visit function of the visitor once for each file or directory in a single directory.

This function does not explore subdirectories.

参数
DirectoryThe directory to iterate the contents of.
VisitorVisitor to call for each element of the directory
返回
false if the directory did not exist or if the visitor returned false.

◆ IterateDirectoryStatRecursively()

bool FFileManagerGeneric::IterateDirectoryStatRecursively ( const TCHAR *  Directory,
IPlatformFile::FDirectoryStatVisitor &  Visitor 
)
override

Call the Visit function of the visitor once for each file or directory in a directory tree.

This function explores subdirectories.

参数
DirectoryThe directory to iterate the contents of, recursively.
VisitorVisitor to call for each element of the directory and each element of all subdirectories.
返回
false if the directory did not exist or if the visitor returned false.

◆ SendMessageToServer()

virtual bool FFileManagerGeneric::SendMessageToServer ( const TCHAR *  Message,
IPlatformFile::IFileServerMessageHandler *  Handler 
)
inlineoverridevirtual

Sends a message to the file server, and will block until it's complete.

Will return immediately if the file manager doesn't support talking to a server.

参数
MessageThe string message to send to the server
返回
true if the message was sent to server and it returned success, or false if there is no server, or the command failed

该类的文档由以下文件生成: