Event
Less than 1 minute
Event
Represents a migration event, which is a collection of migration actions to be executed together.
class Event extends \Hazaar\DBI\Manager\Migration\StructHandles construction, serialization, and execution of grouped migration actions.
Properties
actions
The list of actions to execute as part of the event.
public array $actionsMethods
construct
Initializes the event from the provided actions data.
public construct(mixed $actions): voidEnsures the actions are wrapped in an array and sets up serialization hooks.
Parameters
| Parameter | Type | Description |
|---|---|---|
$actions | mixed | The actions data to initialize from. Modified by reference. |
run
Executes all actions in the event.
public run(Adapter $dbi): boolLogs an error and stops execution if any action fails.
Parameters
| Parameter | Type | Description |
|---|---|---|
$dbi | Adapter | the database adapter instance |
add
public add(ActionName $actionName, ActionType $actionType, BaseAction $actionSpec): ActionParameters
| Parameter | Type | Description |
|---|---|---|
$actionName | ActionName | |
$actionType | ActionType | |
$actionSpec | BaseAction |
Generated by Hazaar API Doc Generator on Tue, 21 Apr 2026 04:00:24 +0000