Skip to content
docsv0.1.0

RunHistory

The adjudicated history of governance runs for a plan: the list of observed entries and the pure reducers that summarize it. Makes queryable what used to be ephemeral — until now only the most recent run was read; `RunHistory` preserves the whole series.

RunHistory::__construct()

public function __construct(string $planHash, array $entries):

Parameters

Parameters of __construct()
NameTypeDescription
$planHashstringIntegrity hash of the plan this history corresponds to
$entrieslist<RunHistoryEntry>Entries of the history, in the observed order

RunHistory::summary()

public function summary(): array

Counts entries by adjudicated state and by producer type. The per-producer count (`byProducer`) skips entries with no run (`run === null`): unreadable entries have no producer to count.

RunHistory::current()

public function current(): array

Filters the entries whose evidence is valid for the current plan.

Returns

only entries with CURRENT state

RunHistory::toArray()

public function toArray(): array

Serializes the history to an array for storage or transmission.