/**
  * Get a list of plugins on construct for later use
  */
 public function __construct()
 {
     foreach (CakePlugin::loaded() as $plugin) {
         $this->_pluginPaths[$plugin] = CakePlugin::path($plugin);
     }
     parent::__construct();
 }
 public function __construct(IRouter $router, IHttpRequest $httpRequest)
 {
     $this->router = $router;
     $this->httpRequest = $httpRequest;
     $this->routers = new ArrayObject();
     parent::__construct('RoutingDebugger', array($this, 'renderTab'), array($this, 'renderPanel'));
 }
Пример #3
0
 /**
  * Constructor - sets up the log listener.
  *
  * @return \LogPanel
  */
 public function __construct()
 {
     parent::__construct();
     $existing = CakeLog::configured();
     if (empty($existing)) {
         CakeLog::config('default', array('engine' => 'FileLog'));
     }
     CakeLog::config('debug_kit_log_panel', array('engine' => 'DebugKit.DebugKitLog', 'panel' => $this));
 }
Пример #4
0
 /**
  * Constructor
  *
  * @param array $settings Array of settings.
  * @return void
  */
 public function __construct($settings)
 {
     parent::__construct();
     $this->title = __d('clear_cache', 'Clear Cache');
     foreach (glob(CACHE . '*', GLOB_ONLYDIR) as $folder) {
         $length = strrpos($folder, DS) + 1;
         $this->folders[] = substr($folder, $length);
     }
     $configured = array_diff(Cache::configured(), array('debug_kit'));
     $this->engines = array_merge($this->engines, $configured);
     foreach (array('folders', 'engines') as $property) {
         if (isset($settings['clear_cache'][$property])) {
             $this->{$property} = (array) $settings['clear_cache'][$property];
         }
     }
 }
Пример #5
0
 /**
  * Constructor - sets up the log listener.
  *
  * @return void
  */
 function __construct($settings)
 {
     parent::__construct();
     if (!class_exists('CakeLog')) {
         App::import('Core', 'CakeLog');
     }
     $existing = CakeLog::configured();
     if (empty($existing)) {
         CakeLog::config('default', array('engine' => 'FileLog'));
     }
     CakeLog::config('debug_kit_log_panel', array('engine' => 'DebugKitLogListener', 'panel' => $this));
 }
Пример #6
0
 public function __construct()
 {
     parent::__construct();
 }