Spectre.GAM.Attempt.Observer behaviour (Spectre v0.4.0)

Copy Markdown View Source

Trusted Domain adapter for independently obtaining a late world observation.

The adapter may verify a provider receipt or query an external system, but it does not receive an execution capability. It is fixed when the Domain starts; callers can supply input to it but cannot replace it per request.

Summary

Types

observation()

@type observation() :: %{
  evidence: Spectre.GAM.Evidence.t() | [Spectre.GAM.Evidence.t()],
  details_ref: String.t()
}

result()

@type result() ::
  {:ok, Spectre.GAM.Outcome.status(), String.t() | nil, observation()}
  | {:error, term()}

Callbacks

observe(t, t, term, keyword)

@callback observe(Spectre.GAM.Act.t(), Spectre.GAM.Attempt.t(), term(), keyword()) ::
  result()