Liking cljdoc? Tell your friends :D

co.multiply.machine-latch.common

Shared compile-time helpers for machine-latch validation and compilation.

Shared compile-time helpers for machine-latch validation and compilation.
raw docstring

compile-transition-fnclj/s

(compile-transition-fn transitions state->idx)

Compile transitions map to a nested case function. Input: {action-kw {from-idx to-idx, ...}, ...} Output: (fn [action from-idx] (case action ...))

Compile transitions map to a nested case function.
Input: {action-kw {from-idx to-idx, ...}, ...}
Output: (fn [action from-idx] (case action ...))
sourceraw docstring

terminal-statesclj/s

(terminal-states transitions)

Returns states that appear as destinations but never as sources. A valid machine has exactly one terminal state.

Returns states that appear as destinations but never as sources.
A valid machine has exactly one terminal state.
sourceraw docstring

validate-machine!clj/s

(validate-machine! {:keys [states transitions]})

Validates machine spec. Throws on invalid spec.

Validates machine spec. Throws on invalid spec.
sourceraw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close