public async Task ReadAsync()

in AdlsDotNetSDK/AdlsInputStream.cs [276:301]


        public async Task<int> ReadAsync(long position, byte[] output, int offset, int count)
        {
            if (output == null)
            {
                throw new ArgumentNullException(nameof(output));
            }
            if (output != null && (offset >= output.Length || offset < 0))
            {
                throw new ArgumentOutOfRangeException(nameof(offset));
            }
            if (output != null && count + offset > output.Length)
            {
                throw new ArgumentOutOfRangeException(nameof(count));
            }
            OperationResponse resp = new OperationResponse();
            int bytesRead = await Core.OpenAsync(Filename, SessionId, position, output, offset, count, Client, new RequestOptions(Client.GetPerRequestTimeout(), new ExponentialRetryPolicy()), resp).ConfigureAwait(false);
            if (!resp.IsSuccessful)
            {
                throw Client.GetExceptionFromResponse(resp, $"Error in reading file {Filename} at offset {position}.");
            }
            if (IpStreamLog.IsTraceEnabled)
            {
                IpStreamLog.Trace($"ADLFileInputStream.Read, Read offset {offset} for file {Filename} for client {Client.ClientId}");
            }
            return bytesRead;
        }