File handle interface.
更多...
#include <GenericPlatformFile.h>
|
| virtual bool | Flush (const bool bFullFlush=false)=0 |
| | Flushes file handle to disk. 更多...
|
| |
| virtual bool | Read (uint8 *Destination, int64 BytesToRead)=0 |
| | Read bytes from the file. 更多...
|
| |
| virtual bool | Seek (int64 NewPosition)=0 |
| | Change the current write or read position. 更多...
|
| |
| virtual bool | SeekFromEnd (int64 NewPositionRelativeToEnd=0)=0 |
| | Change the current write or read position, relative to the end of the file. 更多...
|
| |
|
virtual int64 | Size () |
| | Return the total size of the file
|
| |
|
virtual int64 | Tell ()=0 |
| | Return the current write or read position.
|
| |
| virtual bool | Truncate (int64 NewSize)=0 |
| | Truncate the file to the given size (in bytes). 更多...
|
| |
| virtual bool | Write (const uint8 *Source, int64 BytesToWrite)=0 |
| | Write bytes to the file. 更多...
|
| |
|
virtual | ~IFileHandle () |
| | Destructor, also the only way to close the file handle
|
| |
◆ Flush()
| virtual bool IFileHandle::Flush |
( |
const bool |
bFullFlush = false | ) |
|
|
pure virtual |
Flushes file handle to disk.
- 参数
-
| bFullFlush | true to flush everything about the file (including its meta-data) with a strong guarantee that it will be on disk by the time this function returns, or false to let the operating/file system have more leeway about when the data actually gets written to disk |
- 返回
- true if operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
◆ Read()
| virtual bool IFileHandle::Read |
( |
uint8 * |
Destination, |
|
|
int64 |
BytesToRead |
|
) |
| |
|
pure virtual |
Read bytes from the file.
- 参数
-
| Destination | Buffer to holds the results, should be at least BytesToRead in size. |
| BytesToRead | Number of bytes to read into the destination. |
- 返回
- true if the operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
◆ Seek()
| virtual bool IFileHandle::Seek |
( |
int64 |
NewPosition | ) |
|
|
pure virtual |
Change the current write or read position.
- 参数
-
| NewPosition | new write or read position |
- 返回
- true if the operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
◆ SeekFromEnd()
| virtual bool IFileHandle::SeekFromEnd |
( |
int64 |
NewPositionRelativeToEnd = 0 | ) |
|
|
pure virtual |
Change the current write or read position, relative to the end of the file.
- 参数
-
| NewPositionRelativeToEnd | new write or read position, relative to the end of the file should be <=0! |
- 返回
- true if the operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
◆ Truncate()
| virtual bool IFileHandle::Truncate |
( |
int64 |
NewSize | ) |
|
|
pure virtual |
Truncate the file to the given size (in bytes).
- 参数
-
| NewSize | Truncated file size (in bytes). |
- 返回
- true if the operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
◆ Write()
| virtual bool IFileHandle::Write |
( |
const uint8 * |
Source, |
|
|
int64 |
BytesToWrite |
|
) |
| |
|
pure virtual |
Write bytes to the file.
- 参数
-
| Source | Buffer to write, should be at least BytesToWrite in size. |
| BytesToWrite | Number of bytes to write. |
- 返回
- true if the operation completed successfully.
在 FPakFileHandle< ReaderPolicy > 内被实现.
该类的文档由以下文件生成: