encode method

  1. @override
ByteBuffer encode(
  1. bool data
)
override

Implementation

@override
ByteBuffer encode(bool data) {
  final bytes = ByteData(1);
  bytes.setUint8(0, data ? 1 : 0);
  return bytes.buffer;
}