bufferedCount property
int
get
bufferedCount
Returns the number of bytes currently available in the buffer.
Returns
The number of bytes that can be read without accessing the underlying stream.
Example
final buffered = BufferedInputStream(FileInputStream('data.bin'));
await buffered.readByte(); // This may fill the buffer
print('Bytes in buffer: ${buffered.bufferedCount}');
Implementation
int get bufferedCount => _count - _position;