statement property

  1. @override
String get statement
override

Outputs statement to be interpreted by SQLite

Implementation

@override
String get statement {
  var statement = ['CREATE'];
  if (unique) statement.add('UNIQUE');

  final columnNames = columns.map((c) => '`$c`').join(', ');
  statement.add('INDEX IF NOT EXISTS $name on `$onTable`($columnNames)');
  return statement.join(' ');
}