# fsl v0.2.0 - Table of Contents

> The Finite State Language: describe a process as a finite state machine, and plug a protocol into it.

## Pages

- [Changelog](changelog.md)
- [The Finite State Language and its engine — as-built design](design.md)

- Getting started
  - [FSL for Elixir](readme-1.md)
  - [Samples](readme-2.md)

## Modules

- The language
  - [FSL.Block](FSL.Block.md): Declares a **service building block**: a reusable fragment of a flow, written
in FSL, that other machines call.
  - [FSL.Context](FSL.Context.md): The state a machine keeps about itself, and the macros a state body reads and
writes it with.
  - [FSL.Machine](FSL.Machine.md): The Finite State Language: describes a process as a finite state machine, à la
ExUnit.

- The engine
  - [FSL.Child](FSL.Child.md): Handle on a sub-FSM (child scenario) spawned from a parent scenario via the
`spawn_fsm` macro of `FSL.Machine`.
  - [FSL.Loader](FSL.Loader.md): Finds the machine a caller asked for, by module name or by file path.
  - [FSL.Runner](FSL.Runner.md): Execution engine for `FSL.Machine` finite state machines.

- The embedding
  - [FSL.Host](FSL.Host.md): Connects FSL to the application it runs inside.
  - [FSL.Host.Default](FSL.Host.Default.md): The host of a state machine that embeds no protocol: a plain `%FSL.Context{}`,
nothing to start, no hooks.

- Instrumentation
  - [FSL.Diagram](FSL.Diagram.md): What a renderer of `FSL.Journal` has to provide.
  - [FSL.Diagram.Mermaid](FSL.Diagram.Mermaid.md): Renders an `FSL.Journal` run as a [Mermaid](https://mermaid.js.org/) sequence
diagram.
  - [FSL.Diagram.PlantUML](FSL.Diagram.PlantUML.md): Renders a run recorded by `FSL.Journal` as a
[PlantUML](https://plantuml.com/sequence-diagram) sequence diagram. The
default renderer; `FSL.Diagram.Mermaid` is the alternative, and an application
chooses with `c:FSL.Host.diagram_renderer/0`.
  - [FSL.Journal](FSL.Journal.md): Records one run, so that it can be drawn afterwards.
  - [FSL.Monitor](FSL.Monitor.md): A live registry of the machines currently running: one row each, updated as
they move.

- Utilities
  - [FSL.HTTP](FSL.HTTP.md): Issues HTTP requests from a machine, as events.
  - [FSL.Valet](FSL.Valet.md): FSL.Valet turns any synchronous processing that takes time into an asynchronous
one whose result is delivered as a single tagged message to the caller.

