Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Conditions

A condition declaration defines a named vocabulary of operational states. The condition name and each variant are identifiers.

condition readiness [
    not_ready
    ready
    drop retired
]

An entity records condition state in its conditions section:

entity "van-110" {
    conditions {
        readiness = ready
        drop former_state
    }
}

A condition value can be referenced through a concrete entity or mutation role:

@"van-110".conditions.readiness
@vehicle.conditions.readiness

The parser and change generator emit condition declarations, variant edits, entity assignments, removals, and condition references. Applying the generated changes rejects duplicate definitions, missing definitions, variants from the wrong vocabulary, and deletion of definitions that current entity state or stored expressions still use.

An entity may hold at most one current variant from each condition. Assigning a new variant replaces the previous value. A missing assignment remains missing; condition declarations do not create default operational state. Condition values support equality and inequality, but they are not ordered or numeric.