Source of file EventManager.php
Size: 1,012 Bytes - Last Modified: 2017-11-08T13:54:24+00:00
/home/travis/build/bluzphp/framework/src/Proxy/EventManager.php
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 | <?php /** * Bluz Framework Component * * @copyright Bluz PHP Team * @link https://github.com/bluzphp/framework */ declare(strict_types=1); namespace Bluz\Proxy; use Bluz\EventManager\EventManager as Instance; /** * Proxy to EventManager * * Example of usage * <code> * use Bluz\Proxy\EventManager; * * EvenManager::attach('event name', function() { * // ... some logic * }); * * EventManager::trigger('event name'); * </code> * * @package Bluz\Proxy * @author Anton Shevchuk * * @method static Instance getInstance() * * @method static Instance attach($eventName, $callback, $priority = 1) * @see Instance::attach() * * @method static string|object trigger($event, $target = null, $params = null) * @see Instance::trigger() */ final class EventManager { use ProxyTrait; /** * Init instance * * @return Instance */ private static function initInstance() { return new Instance(); } } |