columnDefinition property

  1. @override
String get columnDefinition
override

Get this field column definition for creation table.

For example:

firstName TEXT NOT NULL

serverId INT UNIQUE

Implementation

@override
String get columnDefinition {
  String result = '$columnName TEXT';
  if (notNull == true) result += ' NOT NULL';
  if (isUnique == true) result += ' UNIQUE';
  return result;
}