Skip to main content

Module storage

Module storage 

Source

Structs§

CreateOutcome
Result of an insert. last_insert_id is backend-dependent (MySQL yields an autoincrement id; Postgres a RETURNING id when available).
FilterClause
A single column filter applied to a list query.
ListPage
One page of rows plus the total count for pagination.
QueryOptions
Pagination + ordering + filters distilled from a request query string.

Enums§

FilterOp
How a FilterClause value is matched.
StorageError

Traits§

Storage

Functions§

seed
Seed the database by running a batch of raw statements against the active backend, in order, stopping at the first error. Write SQL when using a SeaORM backend, or JSON command documents when using Mongo — the same call works for both, you just author for whichever backend you registered.
set_storage
Register the global storage backend. Call once during startup.
storage
Access the global storage backend. Panics if never initialized.