SqfEntityModel constructor
const
SqfEntityModel({
- String? databaseName,
- List<
SqfEntityTable> ? databaseTables, - String? bundledDatabasePath,
- String? modelName,
- List<
SqfEntitySequence> ? sequences, - List<
SqfEntityTable> ? formTables, - String? password,
- List<
String> ? ignoreForFile, - int? dbVersion,
- List<
SqfEntityField> ? defaultColumns, - PreSaveAction? preSaveAction,
- LogFunction? logFunction,
- String? databasePath,
This class is required for DB MODEL definitions using in /lib/model/model.dart file Simple DB Model definition must be below:
@SqfEntityBuilder(myDbModel)
const myDbModel = SqfEntityModel(
modelName: 'MyDbModel',
databaseName: 'sample.db',
databaseTables: [tableProduct, tableCategory, tableTodo],
defaultColumns: [
SqfEntityField('dateCreated', DbType.datetime,
defaultValue: 'DateTime.now()'),
]);
Implementation
const SqfEntityModel(
{this.databaseName,
this.databaseTables,
this.bundledDatabasePath,
this.modelName,
this.sequences,
this.formTables,
this.password,
this.ignoreForFile,
this.dbVersion,
this.defaultColumns,
this.preSaveAction,
this.logFunction,
this.databasePath});