writeToStream static method
- CompoundTag tag, [
- void onWriteListener()?
Implementation
static Uint8List writeToStream(CompoundTag tag,
[void Function(int)? onWriteListener]) {
_io.disposeStream();
_io = ByteLayer();
_io.addListener(onWriteListener);
Tag.writeNamedTag(tag, _io);
return _io.bytes;
}