ExGAM.Attempt.Observer behaviour (ExGAM v0.1.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

Callbacks

Uses the supplied lookup material to verify a late external result for the Act and Attempt.

Types

observation()

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

result()

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

Callbacks

observe(t, t, term, keyword)

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

Uses the supplied lookup material to verify a late external result for the Act and Attempt.