ASM.Pipeline (ASM v0.9.2)

Copy Markdown View Source

Synchronous event pipeline with optional event injection.

Summary

Types

plug_ref()

@type plug_ref() ::
  module()
  | (ASM.Event.t(), map() -> {:ok, ASM.Event.t(), map()})
  | {module(), keyword()}

Functions

run(event, plugs, ctx \\ %{})

@spec run(ASM.Event.t(), [plug_ref()], map()) ::
  {:ok, [ASM.Event.t()], map()} | {:error, ASM.Error.t(), map()}