Expand description
The FACTORED UNITS the grammar words compose and the standalone derives are the bare doors of. The FACTORED UNITS: the per-column emissions a grammar word composes, and the same emissions a standalone derive is the bare door of.
§One authority, by construction
A record’s Filter, Comparison and OrderBy faces are each a per-column walk over a header and a
list of rows. #[ingraph::record(…)] composes those walks and adds storage and wire extras;
#[derive(ingraph::Filter)] and its two siblings compose the SAME walks and add nothing;
#[ingraph::interface(…)] composes the filter and the order-by and adds the crossing, the term
and the entry points. So the three doors’ faces cannot drift: there is one emitter, and what
separates a door from its neighbour is which rows it hands that emitter.
The units take ROWS and not a model, which is what makes that true rather than aspirational: a model is what the record front end builds, and a unit that read one could only ever serve the record. Each row is the smallest thing the walk reads — a member, the NOUN a sentence calls it, the tokens the walk splices, and the paragraph a front end has to add — so a further front end supplies rows without owning a model at all.
The nouns and the paragraphs are the caller’s for one reason, stated once here and at each
field: a walk that read a MODE to choose between the title column and the shared title
column would be the near-duplicate again with a branch in it. The party that knows which is true
spells it; the shape is never asked to guess.
The identity is PINNED beside the by-construction argument: the same struct through the grammar word and through the bare derive, compared as TOKENS.
§What is NOT here
The per-database LOWERINGS (ComplexComparison, the ORDER BY clause builders, the order terms)
and the storage extras. Those are the grammar words’ own additions — a standalone type has no
table to render against — and the split is the ruling’s: the units are what the words COMPOSE,
and storage and wire extras are what the words ADD.
The ORDER-BY face is four functions rather than one, and the split follows the record’s own
GATES: the enum and direction exist wherever a term does, identity exists where a page can be
completed, and subject_path exists wherever a wire order is decoded. A unit that emitted all
three together would put a method on a record that has no page to use it.
§The WIRE faces are here too, and B-27 is what put them here
wire carries the InputType impls the filter’s struct and the order-by’s enum
wear. They were a record’s alone until an interface joined the emitted root, which is what a
filter and an order-by are SPENT by — so the same argument the struct halves already answered
reaches the faces: one emitter, and what separates a door from its neighbour is which rows it
hands that emitter.
Modules§
- wire
- The two INPUT FACES a unit’s types wear —
InputTypeover the filter’s struct and over the order-by’s enum — written once for every front end that emits one.
Structs§
- Comparison
Column - One column, as the COMPARISON unit reads it.
- Filter
Column - One column, as the FILTER unit reads it.
- Lowering
Column - One column, as the comparison’s LOWERING reads it.
- Lowering
Seats - The framework seats the LOWERING spells, resolved by the caller through its own shelf.
- Order
Column - One column, as the ORDER-BY unit reads it.
- Unit
Header - What every unit needs of its caller before it reads a single column.
Functions§
- comparison
- The COMPARISON face: a struct holding one crossed comparison per column, over a database
parameter, under the
whereclause its field types are well formed by. - comparison_
lowering - The comparison’s LOWERING:
ComplexComparison, threading one accumulator through the columns. - filter
- The FILTER face: a struct with one optional filter per column, and the builder pair per member.
- order_
by - The ORDER-BY face: one variant per orderable column, each CARRYING its direction, plus the question every term answers whatever a database does with it.
- order_
identity - The SEMANTIC IDENTITY method — the one input a cursor’s SIGNATURE takes from a term.
- order_
subject_ path - THE SAME identity, as the wire’s decode reads it: a PATH rather than one name, and answered through a trait so a decoder generic over the term type can ask.