Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests.
public override ValueTask<int> ReadAsync(Memory<byte> buffer, CancellationToken cancellationToken)
Asynchronously reads a sequence of bytes from the current stream, advances the position within the stream by the number of bytes read, and monitors cancellation requests.
public override Task<int> ReadAsync(byte[] buffer, int offset, int count,
CancellationToken cancellationToken)