generation library
Support types the code generator and generated files depend on.
Application code does not import this. Import the generated
AppDatabase barrel. The generator (mssql_orm_dev) imports this
rather than the full orm.dart, so its dependency surface is explicit:
binding, field, write-command and scope types, and nothing else.
Repository, relation loader and observer stay out of the generator's
import graph.
Classes
-
AbsentField<
T> - The column is not named in the statement.
-
Field<
T> - The difference between "the caller did not mention this column" and "the caller set this column to NULL".
-
MssqlAppDatabase<
TSelf extends MssqlAppDatabase< TSelf> > - The entry point for ORM access: holds a session and produces table queries.
- MssqlBoundColumn
- One column, as generated code describes it to the runtime.
- MssqlBoundValue
- A value bound as a parameter, already encoded for its column's SQL type.
- MssqlClock
- Which server clock the runtime uses for timestamp columns.
- MssqlColumnSchema
- MssqlDefaultValue
-
The column's declared default, written as the
DEFAULTkeyword. -
MssqlEntityQuery<
TRow, TFields, S extends MssqlEntityQuery< TRow, TFields, S> > - Abstract base for generated table queries, preserving the concrete query type through every entity-preserving call.
- MssqlForeignKeySchema
- MssqlPrimaryKeySchema
-
MssqlQueryContext<
TRow> - Everything a terminal needs to execute a query against one table: the session, the binding, the clock, the dialect and the observer.
- MssqlQueryState
- Immutable snapshot of every selection a query carries: scope state, user predicates, ordering, and native execution options.
- MssqlSchemaReader
- Reads table and view shapes from SQL Server's catalog views.
- MssqlSchemaSnapshot
- A database's shape, written to a file, so that generating code does not need a live database.
- MssqlScope
- A predicate applied to every read of a table, unless it is switched off.
- MssqlScopeCompiler
- Builds the MssqlCondition list a query carries for a given binding and scope selection, once.
- MssqlScopeSelection
- Immutable snapshot of which scopes a query carries.
- MssqlServerValue
-
SQL the server evaluates, such as
SYSDATETIME()or[Hits] + @n. - MssqlSoftDelete
- How a table records a soft delete.
-
MssqlTableBinding<
TRow> - Everything generated code tells the runtime about one table.
- MssqlTableSchema
- What a table or view is made of, as SQL Server reports it.
- MssqlTimestamps
- Which columns carry the created and updated stamps.
- MssqlTriggerSchema
- A trigger, with the timing and events that decide what a write can read back.
-
MssqlTypeConverter<
TDart, TSql> - Converts between a Dart type and what SQL Server stores.
- MssqlUniqueKeySchema
- A unique index or constraint.
- MssqlUntypedDatabase
- A database with no generated table getters, for query-builder-only use.
- MssqlWriteAssignments
- The columns one write names, and what each of them gets.
-
MssqlWriteEngine<
TRow> - The one place insert, update, delete and upsert are executed.
- MssqlWriteOutcome
- What a write did, and how well that is known.
- MssqlWriteValue
- One column's contribution to a write.
-
ValueField<
T> - The column is named and carries value.
Enums
- MssqlAffectedRowsSource
- Where an affected-row count came from, so a caller can judge it.
- MssqlInsertStrategy
- How a row's key comes back from an insert.
- MssqlTrashed
- Whether a soft-deleting repository sees deleted rows.
- MssqlTriggerKind
- What kind of trigger the target table carries.
- MssqlWriteReadback
- How a write finds out what it stored.
Constants
-
textOnlySqlTypes
→ const Set<
String> -
Types the driver has no dedicated model for, which
dbconvertreturns as their canonical text.
Functions
-
fingerprintOf(
MssqlTableSchema table) → String - A stable digest of the parts of a table that generated code depends on.
-
mssqlTypeForSqlTypeName(
String sqlTypeName) → MssqlType? -
The driver's classification of
sqlTypeName, or null if nothing here recognises it.