Expand description
Pure, DB-free logical→physical transaction lowering.
This module is the single source of truth for the from→to FX math used by every client surface (CLI, TUI, web) and the upcoming B2b RPC native. No database calls, no async.
Structs§
- Logical
Split - A from→to exchange;
to_amountis required ifffrom_commodity != to_commodity. - Physical
Split - One physical ledger entry.
- Price
Row - One price-table row linking two physical splits.
Functions§
- lower_
logical_ split - Lower one logical split to two physical splits and an optional price row.
- lower_
logical_ transaction - Lower a non-empty slice of logical splits into physical splits and price rows.