GeneratedView<Row extends Object, Self extends GeneratedView<Row, Self>> class abstract interface

The common superclass for view classes generated by drift_dev.

Implemented types

Properties

alias → String?
When created through withAlias, an alias for this result set.
no setterinherited
aliasOrName → String
If an alias is set, the alias. Otherwise, the entityName for this result set.
no setterinherited
columns → List<SchemaColumn<Object>>
The columns of this result set.
no setterinherited
columnsByName → Map<String, SchemaColumn<Object>>
All columns, indexed by their name.
latefinalinherited
entityName → String
The default name of this result set (if no alias is set).
no setterinherited
hashCode → int
The hash code for this object.
no setterinherited
query → SelectStatement?
For views defined in Dart, the select statement backing this view.
no setter
readsFrom → Set<String>
The names of tables that this view is reading from.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
sqlDefinition → CustomComponent?
If query is not available, the generated SQL text for this view.
no setter

Methods

asSelfType() → Self
Type-level hack: Result sets are supposed to inherit from the Self type they declare, so this returns just this.
inherited
createMapperFromPositions(DriftDialect dialect, List<ColumnPosition> positions) → Row? Function(RawRow)
Like createMapperToDart, but with positions already resolved.
inherited
createMapperToDart(DriftDialect dialect, ResultSetStructure structure) → Row? Function(RawRow)
Creates a function that, when receiving a DriftRow, extracts columns for this result set into the mapped Row type.
inherited
mapFromCompanion(Insertable<Row> companion, DriftDialect dialect) → Row
Converts a companion to the real model class, Row.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited
withAlias(String alias) → Self
Returns a new instance of this result set with alias set to the given value.
inherited

Operators

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

Static Methods

defineStatementForView(ResultSet<Object, ResultSet<Object, dynamic>> table, {bool distinct = false}) → SelectStatement
Generates a SelectStatement for query.