PostgresAdapter class final Getting Started

BasaltAdapter for the Postgres backend.

database: options are parsed by PostgresEndpoint.fromOptions — either a single url: or manual host/port/database/username/password/ssl keys. Select it in basalt.yaml with backend: basalt_postgres.

The opt-in nativeTypeOverrides preset (native_types: true) maps json/jsonb columns to Map<String, Object?> via PostgresJsonbSqlType; without it they emit as plain String columns.

Constructors

PostgresAdapter()
const

Properties

hashCode → int
The hash code for this object.
no setterinherited
name → String
Short backend name for diagnostics, e.g. 'sqlite'.
no setter
nativeTypeOverrides → SchemaTypeOverrides
Backend-native generate-schema presets, applied only when the project opts in with native_types: true in basalt.yaml.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
typeOverrides → SchemaTypeOverrides
Always-applied generate-schema presets.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
open(Map<String, Object?> options) → Future<Connection>
Opens a live connection described by options — the raw database: section of basalt.yaml, passed through as-is.
reset(Map<String, Object?> options) → Future<void>
Destroys the database described by options so database reset can rebuild it from scratch by re-running migrations.
toString() → String
A string representation of this object.
inherited

Operators

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