Module find_many
Expand description
Built-in support for the FindMany<Model> procedure-argument type
(.cstack syntax) — search-with-filters for procedures. Composes
with PageInput rather than absorbing it — a procedure wanting both
filtering and pagination declares two arguments, e.g. procedure search(query: FindMany<Post>, page: PageInput): Page<Post>.
This module holds only the one piece that’s genuinely shared across
every model: the per-field operator envelope. Everything else — which
fields a model has, which operators apply to which field — is
per-model and lives in cratestack-macros-generated code
(<Model>Where, <Model>SortField, <Model>OrderByClause,
<Model>FindManyInput), mirroring how Create<Model>Input/
Update<Model>Input are per-model generated structs rather than one
shared generic wrapper.
Structs§
- Field
Filter Input - Every operator a filterable field might support, as one flat
optional-per-operator envelope — generated per-model code reads only
the operators that make sense for a given field’s type (e.g. a
Booleanfield’s generatedto_filters()never looks atcontains).Vis the field’s own scalar Rust type (String,i64,bool,chrono::DateTime<Utc>, …) — neverOption<V>even for an optional field, since these operators describe a value to compare against, not the field’s own nullability (whichis_nullcovers instead).