Interface PluginApplicationInterface
Interface for Applications that leverage plugins & events.
Events can be bound to the application event manager during the application's bootstrap and plugin bootstrap.
- Cake\Core\PluginApplicationInterface implements Cake\Event\EventDispatcherInterface
Direct Implementers
Method Summary
-
addPlugin() public
Add a plugin to the loaded plugin set. -
pluginBootstrap() public
Run bootstrap logic for loaded plugins. -
pluginConsole() public
Run console hooks for plugins -
pluginMiddleware() public
Run middleware hooks for plugins -
pluginRoutes() public
Run routes hooks for loaded plugins
Method Detail
addPlugin() public ¶
addPlugin( string|Cake\Core\PluginInterface
$name , array $config [] )
Add a plugin to the loaded plugin set.
If the named plugin does not exist, or does not define a Plugin class, an
instance of Cake\Core\BasePlugin
will be used. This generated class will have
all plugin hooks enabled.
Parameters
-
string|
Cake\Core\PluginInterface
$name - The plugin name or plugin object.
- array $config optional []
- The configuration data for the plugin if using a string for $name
Returns
$this
pluginConsole() public ¶
pluginConsole( Cake\Console\CommandCollection
$commands )
Run console hooks for plugins
Parameters
-
Cake\Console\CommandCollection
$commands - The CommandCollection to use.
Returns
pluginMiddleware() public ¶
pluginMiddleware( Cake\Http\MiddlewareQueue
$middleware )
Run middleware hooks for plugins
Parameters
-
Cake\Http\MiddlewareQueue
$middleware - The MiddlewareQueue to use.
Returns
pluginRoutes() public ¶
pluginRoutes( Cake\Routing\RouteBuilder
$routes )
Run routes hooks for loaded plugins
Parameters
-
Cake\Routing\RouteBuilder
$routes - The route builder to use.
Returns
Magic methods inherited from Cake\Event\EventDispatcherInterface
getEventManager()
|