Пример #1
0
 public function init()
 {
     // include doctrine
     require_once $this->icingaPath . "lib/doctrine/lib/Doctrine.php";
     spl_autoload_register("Doctrine::autoload");
     // include agavi (needed for configuration)
     require $this->icingaPath . 'lib/agavi/src/agavi.php';
     require $this->icingaPath . 'app/config.php';
     Agavi::bootstrap('production');
     AppKitAgaviContext::buildVersionString();
 }
 /**
  * Loads the agavi and appkit bootstrap
  * TODO:   the appkit bootstrap is not really needed, the console context
  * 		   uses it's factories. Perhaps a "cron" context can be created to minimize
  * 		   memory usage and optimize performance
  *  
  */
 private function bootstrap()
 {
     require_once $this->agaviPath;
     require_once $this->configPath;
     // +---------------------------------------------------------------------------+
     // Setting the running context to web ...
     Agavi::bootstrap('development');
     AgaviConfig::set('core.default_context', 'console');
     AgaviController::initializeModule('AppKit');
     AgaviConfig::set('core.context_implementation', 'AppKitAgaviContext');
     AppKitAgaviContext::getInstance();
 }