diff options
author | Frederic Guillot <fred@kanboard.net> | 2015-09-20 13:11:41 -0400 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2015-09-20 13:11:41 -0400 |
commit | a0124b45f9dab8a0f7d4879d4ea147b414b25bf2 (patch) | |
tree | 4f1a419104374591e269e9f32838ca500245fe1a /app/Core/PluginBase.php | |
parent | fe57edd9e87832dbd14ea8ffd2dc2f16ac1ceb6f (diff) |
Add sub namespace for plugins
Diffstat (limited to 'app/Core/PluginBase.php')
-rw-r--r-- | app/Core/PluginBase.php | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/app/Core/PluginBase.php b/app/Core/PluginBase.php deleted file mode 100644 index 457afa03..00000000 --- a/app/Core/PluginBase.php +++ /dev/null @@ -1,47 +0,0 @@ -<?php - -namespace Core; - -/** - * Plugin Base class - * - * @package core - * @author Frederic Guillot - */ -abstract class PluginBase extends Base -{ - /** - * Method called for each request - * - * @abstract - * @access public - */ - abstract public function initialize(); - - /** - * Returns all classes that needs to be stored in the DI container - * - * @access public - * @return array - */ - public function getClasses() - { - return array(); - } - - /** - * Listen on internal events - * - * @access public - * @param string $event - * @param callable $callback - */ - public function on($event, $callback) - { - $container = $this->container; - - $this->container['dispatcher']->addListener($event, function() use ($container, $callback) { - call_user_func($callback, $container); - }); - } -} |