Skip to main content

Module registry

Module registry 

Expand description

The template registry — the single source for resolving a template code and for enumerating the available templates (the Python namespace is built from it).

Structs§

TemplateError
A code that resolves to no registered template.

Enums§

QuoteFamilyError
Error resolving a template code to its tagged-quote family.

Statics§

REGISTRY
Every group’s table, unioned. Lookup and enumeration scan these in order.

Functions§

codes
Every registered template as (group, name, code) — the enumeration the Python templates.<group>.<name> namespace is generated from.
entries 🔒
The tables hashed by upper-cased code, built once on first use. Insertion order follows the table scan order, first entry winning a duplicate code — identical resolution to the linear scan it replaces.
lookup
Resolves a template code (case-insensitive) to its template.
quote_family
The tagged-quote family (Quote.type) pillars on template code carry — the registry-inferred kind the recipe builder stamps on a pillar, so callers never restate it. The mapping mirrors the calibration-helper dispatch in curves::recipe; an Xccy template maps to the basis-spread "Xccy" family (the directly-observable "FixedFloatXccy" reading is authored through its dedicated builder verb, never inferred). Errors on an unknown code and on a template kind that is not a curve pillar.
template
The registered template under code — the client verb behind the Python template(code), refusing an unknown code by name where lookup answers None.