readCompressed static method

Future<Tag> readCompressed(
  1. String file, [
  2. void onReadListener(
    1. int
    )?
])

Implementation

static Future<Tag> readCompressed(String file,
    [void Function(int)? onReadListener]) async {
  _io.disposeStream();
  _io = ByteLayer();
  _io.addListener(onReadListener);
  await _io.readFromFile(file);
  await _io.decompress();
  _io.resetPosition();
  return Tag.readNamedTag(_io);
}