AdlsInputStream.ReadAsync Method

Definition

Overloads

ReadAsync(Byte[], Int32, Int32, CancellationToken)

Reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read Asynchronous operation.

ReadAsync(Int64, Byte[], Int32, Int32)

Reads a sequence of bytes directly from the server. It does not update anything in the stream.

ReadAsync(Byte[], Int32, Int32, CancellationToken)

Reads a sequence of bytes from the current stream and advances the position within the stream by the number of bytes read Asynchronous operation.

public override System.Threading.Tasks.Task<int> ReadAsync (byte[] output, int offset, int count, System.Threading.CancellationToken cancelToken);
override this.ReadAsync : byte[] * int * int * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
Public Overrides Function ReadAsync (output As Byte(), offset As Integer, count As Integer, cancelToken As CancellationToken) As Task(Of Integer)

Parameters

output
System.Byte[]

Output byte array

offset
System.Int32

offset at which data should be put in the output array

count
System.Int32

Count of the bytes read

cancelToken
System.Threading.CancellationToken

Cancellation Token

Returns

System.Threading.Tasks.Task<System.Int32>

Number of bytes read

Applies to

ReadAsync(Int64, Byte[], Int32, Int32)

Reads a sequence of bytes directly from the server. It does not update anything in the stream.

public System.Threading.Tasks.Task<int> ReadAsync (long position, byte[] output, int offset, int count);
override this.ReadAsync : int64 * byte[] * int * int -> System.Threading.Tasks.Task<int>
Public Function ReadAsync (position As Long, output As Byte(), offset As Integer, count As Integer) As Task(Of Integer)

Parameters

position
System.Int64

Position in the file from where it should start reading data

output
System.Byte[]

Output byte array

offset
System.Int32

offset at which data should be put in the output array

count
System.Int32

Count of the bytes read

Returns

System.Threading.Tasks.Task<System.Int32>

Number of bytes read

Applies to