Column class

Table column annotation

Constructors

Column({NameConversion nameConversion = snakeCapitalCaseConversion, String? name, String? dartName, Type? dartType, required SQLDataType type, bool primaryKey = false, bool autoIncrement = false, dynamic idGenerator, dynamic defaultValue, bool unique = false, String? uniqueGroup, bool notNull = true, bool readonly = false, dynamic reader, dynamic writer})
create column annotation
const

Properties

autoIncrement bool
indicate whether the current field is primary key and auto increment
final
dartName String?
name of dart class field represent this column value.
final
dartType Type?
An actual dart type for the field that represent the current column
final
defaultValue → dynamic
Default value for this field
final
hashCode int
The hash code for this object.
no setterinherited
idGenerator → dynamic
A reference to a function use as generator to create new id for a new object.
final
name String?
name of column if given otherwise field name is use instead.
final
nameConversion NameConversion
function use to convert name between dart and sql
final
notNull bool
Indicate whether the column is nullable.
final
primaryKey bool
indicate whether the current field is represent primary key
final
reader → dynamic
A reference function use to parse data from SQLite to Dart object.
final
readonly bool
indicate that the field or column is not allow to be editable.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
type SQLDataType
Data type of current field in the sqlite table
final
unique bool
indicate whether the column is unique
final
uniqueGroup String?
a string id represent unique group or a single unique column
final
writer → dynamic
A reference function use to convert unsupported database to SQLite Data Type.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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