mapSync method
Maps a whole file read-only.
Backends that cannot map (in-memory, web) may return a plain view; the contract is only that MappedFile.bytes stays valid until close.
Implementation
@override
MappedFile mapSync(String name) {
final file = _files[name];
if (file == null) throw StateError('no such file: $name');
return _MemoryMappedFile(file.bytes);
}