adapter library

API for implementation of custom DatabaseAdapter for package:typed_sql.

You should only ever need to import this library, if you are implementing a custom DatabaseAdapter.

Warning

This interface is NOT stable yet, while subclasses of DatabaseAdapter is possible outside package:typed_sql, newer versions of this package may add new methods (remove existing) without a major version bump!

Classes

DatabaseAdapter Testing
Interface that a database adapter must implement.
DatabaseTransaction
Interface for executing database operations in a transaction.
Executor
Interface for executing database operations.
QueryResult
Result of executing an SQL statement.
RowReader
Interface for reading rows from a database.

Functions

throwTransactionAbortedException(Exception reason) → Never
Throw a TransactionAbortedException with the given reason.

Exceptions / Errors

AuthenticationException Exceptions
Thrown when authentication with the database failed.
ConstraintViolationException Exceptions
Thrown when an operation was aborted because a constraint violation in the database.
DatabaseConnectionBrokenException Exceptions
Thrown when the database connection was broken.
DatabaseConnectionException Exceptions
Thrown when there is an issue with the database connection.
DatabaseConnectionForceClosedException Exceptions
Thrown when the database connection is force closed.
DatabaseConnectionRefusedException Exceptions
Thrown when the database connection was refused.
DatabaseConnectionTimeoutException Exceptions
Thrown when a connection timeout happened.
DatabaseException Exceptions
Base class for all exceptions thrown by package:typed_sql.
DivisionByZeroException Exceptions
Thrown when a division by zero happened in the database.
IntermittentConnectionException Exceptions
Thrown when there is an intermittent issue with the database connection.
OperationException Exceptions
Thrown when the database reports an error while executing an operation.
TransactionAbortedException Exceptions
Thrown when a transaction was rolled back.
TypeCastException Exceptions
Thrown when an SQL type cast fail in the database.
UnspecifiedOperationException Exceptions
An unspecified OperationException.