Version: 2021.3

ReadHandle

struct in Unity.IO.LowLevel.Unsafe

切换到手册

描述

可以使用此句柄来查询异步读取操作的状态。注意:为避免内存泄漏,必须调用 Dispose。

变量

JobHandle在读取操作完成时完成的 JobHandle。
ReadCountThe number of read commands performed for this read operation. Will return zero until the reads have begun.
Status读取操作的当前状态。

公共函数

CancelCancels the AsyncReadManager.Read operation on this handle.
Dispose处置 ReadHandle。将其用于释放内部资源以便重用。
GetBytesReadReturns the total number of bytes read by all the ReadCommand operations the asynchronous file read request.
GetBytesReadArrayReturns an array containing the number of bytes read by the ReadCommand operations during the asynchronous file read request, where each index corresponds to the ReadCommand index.
IsValid检查 ReadHandle 是否有效。