IsolatedStorageFileStream.EndRead(IAsyncResult) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
结束挂起的异步读取请求。
public:
override int EndRead(IAsyncResult ^ asyncResult);
public override int EndRead(IAsyncResult asyncResult);
override this.EndRead : IAsyncResult -> int
Public Overrides Function EndRead (asyncResult As IAsyncResult) As Integer
参数
- asyncResult
- IAsyncResult
挂起的异步请求。
返回
从流中读取的字节数,介于零和请求的字节数之间。 流仅返回流末尾的零。 否则,它们将阻止,直到至少有一个字节可用。
例外
asyncResult 是 null。
注解
EndRead 必须在每个 IAsyncResult 对象 BeginRead上完全调用一次,调用 EndRead 是知道从中 Stream读取的字节数的唯一方法。 EndRead 将在 I/O 操作完成之前阻止。