read method

  1. @override
int read(
  1. String path,
  2. Uint8List target,
  3. int offset
)
override

Reads a chunk of the file at path and offset offset into the target buffer.

Returns the amount of bytes read.

Implementation

@override
int read(String path, Uint8List target, int offset) {
  final type = _recognizeType(path);
  if (type == null) {
    return _memory.read(path, target, offset);
  } else {
    return _files[type]!.read(target, FileSystemReadWriteOptions(at: offset));
  }
}