# `WorkflowStem.Compiler.Resolvers`
[🔗](https://github.com/fosferon/workflow_stem/blob/main/lib/workflow_stem/compiler/resolvers.ex#L1)

Internal ALF-switch resolvers used by pipelines synthesized via
`WorkflowStem.Compiler.components_for_engine/1`.

These are referenced by `defdelegate` on the runtime-compiled pipeline
module so ALF's `switch` can resolve them in the usual way
(`apply(pipeline_mod, name, [event, opts])`).

# `current_state`

```elixir
@spec current_state(
  map(),
  keyword()
) :: atom() | String.t()
```

Resolver for the synthetic `:__current_state__` switch that dispatches
per-event routing based on the workflow's current state.

The ALF event arriving at the switch carries the full event map we
hand to `WorkflowStem.Pipelines.Stepwise` — i.e. `%{runtime: ..., spec: ...}`.
The current state lives on `runtime.current_state`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
