Spectre.Operation.Ref (Spectre v0.3.0)

Copy Markdown View Source

Stable, portable reference to a Work, Vigil or external controller loop.

Summary

Types

t()

@type t() :: %Spectre.Operation.Ref{
  controller: module() | nil,
  correlation_id: String.t() | nil,
  id: String.t(),
  kind: :work | :vigil | :directive,
  subject_id: String.t()
}

Functions

from_loop(loop)

@spec from_loop(Spectre.Operation.Loop.t()) :: t()

validate(ref)

@spec validate(t()) :: :ok | {:error, term()}

validate!(ref)

@spec validate!(t()) :: t()