writeCompressedSync static method
- String file,
- CompoundTag tag, [
- void onWriteListener()?
Implementation
static void writeCompressedSync(String file, CompoundTag tag,
[void Function(int)? onWriteListener]) {
_io.disposeStream();
_io = ByteLayer();
_io.addListener(onWriteListener);
Tag.writeNamedTag(tag, _io);
_io.compress();
_io.writeToFileSync(file);
}