Hwaro::Core::Lifecycle::Manager
Inherits Reference / Object
Constructors
new(debug : Bool = false)
SourceInstance methods
after(phase : Phase, priority : Int32 = 0, name : String = "anonymous", &block : BuildContext -> HookResult)
Register hook after a phase
before(phase : Phase, priority : Int32 = 0, name : String = "anonymous", &block : BuildContext -> HookResult)
Register hook before a phase
clear
Sourceclear_point(point : HookPoint)
Sourcehas_hooks?(point : HookPoint) : Bool
Sourcehook_count
Sourcehooks_at(point : HookPoint) : Array(RegisteredHook)
Sourceon(point : HookPoint, priority : Int32 = 0, name : String = "anonymous", &block : BuildContext -> HookResult)
Register a hook at a specific point
register_hook(point : HookPoint, handler : HookHandler, priority : Int32 = 0, name : String = "anonymous")
Register handler directly
run_all_phases(context : BuildContext, &phase_action : Phase -> ) : HookResult
Run all phases in sequence
run_phase(phase : Phase, context : BuildContext, &) : HookResult
Execute a phase with before/after hooks
trigger(point : HookPoint, context : BuildContext) : HookResult
Trigger all hooks at a specific point