SqlFileStream.BeginRead Method (Byte[], Int32, Int32, AsyncCallback, Object)
.NET Framework (current version)
Begins an asynchronous read operation.
Assembly: System.Data (in System.Data.dll)
[HostProtectionAttribute(SecurityAction.LinkDemand, ExternalThreading = true)] public override IAsyncResult BeginRead( byte[] buffer, int offset, int count, AsyncCallback callback, object state )
Parameters
- buffer
-
Type:
System.Byte[]
The buffer to read the data into.
- offset
-
Type:
System.Int32
The byte offset in buffer at which to begin writing data read from the stream.
- count
-
Type:
System.Int32
The maximum number of bytes to read.
- callback
-
Type:
System.AsyncCallback
An optional asynchronous callback, to be called when the read is complete.
- state
-
Type:
System.Object
A user-provided object that distinguishes this particular asynchronous read request from other requests
Return Value
Type: System.IAsyncResultAn IAsyncResult that represents the asynchronous read, which could still be pending.
| Exception | Condition |
|---|---|
| NotSupportedException | Reading data is not supported on the stream. |
.NET Framework
Available since 2.0
Available since 2.0
Show: