Expand description
Entity type definitions and the type registry (ADR-0006).
A plugin entity type is data: a JSON-serializable EntityTypeDef with a
typed property schema, derived values, anchors, drawable primitive recipes,
constraint templates and property migrations, all written in the expression
language of crate::lang. Definitions are compiled (parsed, dimension-checked)
at registration; invalid definitions are rejected with typed errors.
Structs§
- Anchor
Def - An anchor definition.
- Circle
Def - Circle-like interpretation for circle rules (concentric, tangency, radius).
- Compiled
Template - A compiled constraint template.
- Compiled
Type - A registered, compiled plugin type.
- Entity
Type Def - A plugin entity type definition.
- Migration
Def - Property migration from
fromtofrom + 1. - Named
Expr - A named expression.
- Param
Info - Solver parameter of a plugin entity.
- Prim
Style - Style of a primitive recipe.
- Registry
- The type registry.
- Template
Def - Constraint template instantiated for every entity of the type.
- Type
Entry - Registry entry.
Enums§
- Compiled
Prim - Compiled primitive recipe.
- DimName
- Physical dimension names used in definitions.
- Number
Lit - A number literal in a definition: a plain number (canonical units) or a string
with a unit such as
"60cm". - OnDelete
- What happens to a referencing entity when its target is deleted.
- Primitive
Def - Drawable primitive recipe.
- PropDef
- Property schema.
- Registry
Error - Registry errors.
- Stay
Level - How strongly a solver property keeps its previous value when rules force changes (relative stay weight).
Functions§
- builtin_
members - Members of built-in types usable through typed references.
- placeholders
{name}placeholders of a text template.