Class Hooks
Hook callbacks.
Methods summary
public static
filter_autoconfig( array & $autoconfig
)
Adds "modules" directories found in the app directories to module-path
.
public static
on_core_configure( ICanBoogie\Core\ConfigureEvent $event
, ICanBoogie\Core $app
)
Extends application configuration according to modules features.
public static
on_core_boot( ICanBoogie\Core\BootEvent $event
, ICanBoogie\Core $app
)
Boot enabled modules.
public static
before_synthesize_routes( ICanBoogie\Binding\Routing\BeforeSynthesizeRoutesEvent $event
)
Alter routes defined by modules by adding a module
key that holds the identifier of the
module that defines the route.
public static
on_template_resolver_alter( ICanBoogie\Render\TemplateResolver\AlterEvent $event
)
Decorates the template resolver with a ICanBoogie\Module\ModuleTemplateResolver
instance.
public static
on_view_alter( ICanBoogie\View\View\AlterEvent $event
, ICanBoogie\View\View $target
)
If the view renders a module's route, the "template" directory of that module is added
to the list of templates locations. Also, the module is set as module
view variable.
public static
get_modules( ICanBoogie\Core $app
)
: ICanBoogie\Module\ModuleCollection
Return the ICanBoogie\Module\ModuleCollection
instance used to manage the modules attached to the core.
public static
get_models( ICanBoogie\Core $app
)
: ICanBoogie\Module\ModelCollection
Returns the ICanBoogie\Module\ModelCollection
instance used to obtain the models defined by the modules.
public static
controller_get_module( ICanBoogie\Routing\Controller $controller
)
: ICanBoogie\Module
Return the ICanBoogie\Module
instance associated with the route handled by the controller.
public static
controller_get_model( ICanBoogie\Routing\Controller $controller
)
: ICanBoogie\ActiveRecord\Model
Return the primary model of the module associated with the route handled by the controller.
public static
controller_lazy_get_records_fetcher( ICanBoogie\Routing\Controller $controller
)
: ICanBoogie\Facets\Fetcher
Return a record fetcher for the controller model
.