toUint8List method Null safety
override
Implementation
@override
Uint8List toUint8List() {
if (isEOS) {
return Uint8List(0);
}
var length = fileRemaining;
final bytes = Uint8List(length);
_file.position = _fileOffset + _position;
final readBytes = _file.readInto(bytes);
skip(length);
if (readBytes != bytes.length) {
bytes.length = readBytes;
}
return bytes;
}