DB class

Properties

database Future<Database>
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

getDB() Future<Database>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onConfigure(List<Future<dynamic Function(Database)>> fn) → void
Executes when creating database. This method should be called before using eloquent.
onCreate(List<Future<dynamic Function(Database, int)>> fn) → void
Executes when creating database. This method should be called before using eloquent.
onDowngrade(List<Future<dynamic Function(Database, int, int)>> fn) → void
Executes when creating database. This method should be called before using eloquent.
onOpen(List<Future<dynamic Function(Database)>> fn) → void
Executes when opening database. This method should be called before using eloquent.
onUpgrade(List<Future<dynamic Function(Database, int, int)>> fn) → void
Executes when creating database. This method should be called before using eloquent.
setDbVersion(int ver) → void
Set db version. Set file name. This method should be called before using eloquent.
setFileName(String name) → void
Set file name. This method should be called before using eloquent.
setFilePath(String path, {bool shouldForceCreatePath = false}) → void
Set file name. This method should be called before using eloquent.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

instance DB
final

Static Methods

createTable(Database db, {required String tableName, required Map<String, Object?> columns}) Future
foreign({required String foreignKey, required String parentKey, required String parentTable, required String type, DBActions? onUpdate, DBActions? onDelete}) String
getAction(DBActions action) String