非同期読み込みリクエストの保留状態を終了します。
Overrides Public Function EndRead( _
ByVal asyncResult As IAsyncResult _) As Integer
[C#]
public override int EndRead(IAsyncResultasyncResult);
[C++]
public: int EndRead(IAsyncResult* asyncResult);
[JScript]
public override function EndRead(
asyncResult : IAsyncResult) : int;
パラメータ
- asyncResult
保留中の非同期の要求。
戻り値
ストリームから読み取ったバイト数 (0 ~要求したバイト数の間の数値)。ストリームは、末尾に達した場合にだけ 0 を返します。それ以外の場合、ストリームは少なくとも 1 バイトが読み取られるまでブロックします。
例外
例外の種類 | 条件 |
---|---|
ArgumentNullException | asyncResult が null 参照 (Visual Basic では Nothing) です。 |
解説
EndRead は、 BeginRead からの各 IAsyncResult ごとに必ず一度呼び出す必要があります。 EndRead の呼び出しは、 Stream から読み取ったバイト数を確認する唯一の方法です。 EndRead は、I/O 操作が完了するまでブロックします。
必要条件
プラットフォーム: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 ファミリ
参照
IsolatedStorageFileStream クラス | IsolatedStorageFileStream メンバ | System.IO.IsolatedStorage 名前空間