DriftView class Null safety
An annotation specifying view properties
- dataClassName → String?
The name for the data class that will be generated for the view class.
The data class is a dart object that will be used to represent a result of
By default, drift will attempt to use the view name followed by "Data"
when naming data classes (e.g. a view named "UserView" will generate a
data class called "UserViewData").
By default, drift will attempt to use the singular form of the table name
when naming data classes (e.g. a table named "Users" will generate a data
class called "User"). However, this doesn't work for irregular plurals and
you might want to choose a different name, for which this annotation can be
- extending → Type?
The parent class of generated data class. Class must extends DataClass!
- hashCode → int
The hash code for this object. [...]
- name → String?
The sql view name to be used. By default, drift will use the snake_case
representation of your class name as the sql view name. For instance, a
View class named
UserViewwill be called
- runtimeType → Type
A representation of the runtime type of the object.