backends library Null safety
Utility classes to implement custom database backends that work together with drift.
- Instruction to run a batched sql statement with the arguments provided.
- Stores information needed to run batched statements in the order they were issued without preparing statements multiple times.
- An interface that supports sending database queries. Used as a backend for drift.
- An interface that supports setting the database version.
- A database engine (implements QueryExecutor) that delegates the relevant work to a DatabaseDelegate.
- A database that supports setting the schema version at any time.
A TransactionDelegate for database APIs which don't already support
creating transactions. Drift will send a
BEGIN TRANSACTIONstatement at the beginning, then block the database, and finally send a
COMMITstatement at the end.
- A database that doesn't support setting schema versions.
- A database that only support setting the schema version while being opened.
- An interface which can execute sql statements.
- A query executor is responsible for executing statements on a database and return their results in a raw form.
- Callbacks passed to QueryExecutor.ensureOpen to run schema migrations when the database is first opened.
- A result from an select statement.
- A TransactionDelegate for database APIs which do support creating and managing transactions themselves.
- An interface to start and manage transactions.
- A QueryExecutor that runs multiple queries atomically.
- A TransactionDelegate for database APIs that have it's own transaction function