Skip to main content

Module caps

Module caps 

Source
Expand description

Capability markers (ReadFoo, …) from #[table] and tuple composition for context generics.

ReducerCaps / QueryCaps compose for nested pairs (A, B) and recurse for schema. CanRead / CanInsert / CanUpdate / CanDelete do not infer through (A, B) (Rust cannot express “either side” without overlapping impls). For multi-table reducer caps, use a module-local zero-sized struct and implement the needed Can* markers per row type (often via a small declarative macro in your crate), delegating ReducerCaps::extend_reducer_schema to a nested tuple of Read* / Insert* / … markers.

Traits§

CanDelete
Delete access for Row.
CanInsert
Insert access for Row.
CanRead
Read access to rows of type Row (the #[table] struct).
CanUpdate
Update access for Row.
QueryCapPiece
One leaf of a query Caps tree.
QueryCaps
ReducerCapPiece
One leaf of a reducer Caps tree: contributes ReducerTableRef entries.
ReducerCaps
Composed reducer capabilities (markers, tuples, or ()).