Expand description
SQL database POD types — DbValue + DbRows (engine-agnostic). The
Db handle + SQLite engine live in azul_dll behind db-sqlite.
POD types for the SQL database surface (SUPER_PLAN_2 §4 P4.3).
Engine-agnostic: the public API is SQL strings plus typed value arrays,
so the engine (bundled SQLite via rusqlite) stays fully hidden behind
the db-sqlite feature in azul-dll. The handle type (Db, wrapping a
rusqlite::Connection) lives in the dll — like App — because it
carries an engine resource; these param/result data types live here in
azul-core (no engine dep) so they’re always present and codegen-able.
Shape: db.execute(sql, params: DbValueVec) -> rows_affected and
db.query(sql, params) -> DbRows. DbValue maps onto SQLite’s five
storage classes.
Structs§
- DbRows
- The result of
db.query(...)— a column-named, row-major value grid. Flat (not nested vectors) for a simple FFI shape: cell(row, col)isvalues[row * num_columns + col]. - DbValue
Vec - DbValue
VecSlice - C-compatible slice type for $struct_name. This is a non-owning view into a Vec’s data.
Enums§
- DbValue
- A single SQL value — a bound statement parameter or a result cell. Mirrors SQLite’s storage classes (Null / Integer / Real / Text / Blob) but names nothing engine-specific.
- DbValue
VecDestructor - Option
DbValue