createRequest method

  1. @override
Buffer createRequest()
override

Returns a Buffer containing the command packet.

Implementation

@override
Buffer createRequest() {
  var encoded = utf8.encode(_dbName);
  var buffer = Buffer(encoded.length + 1);
  buffer.writeByte(COM_INIT_DB);
  buffer.writeList(encoded);
  return buffer;
}