toJson method
Implementation
Map<String, Object?> toJson() => {
'name': name,
'dataType': dataType,
if (schema != null) 'schema': schema,
if (tableName != null) 'tableName': tableName,
if (length != null) 'length': length,
if (numericPrecision != null) 'numericPrecision': numericPrecision,
if (numericScale != null) 'numericScale': numericScale,
if (!nullable) 'nullable': false,
if (defaultValue != null) 'defaultValue': defaultValue,
if (autoIncrement) 'autoIncrement': true,
if (primaryKey) 'primaryKey': true,
if (comment != null) 'comment': comment,
if (generatedExpression != null) 'generatedExpression': generatedExpression,
};