You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
<?php /** * * * @copyright netmonsters.ru * @link * @package Majestic * @subpackage Load * @since * @version SVN: $Id$ * @filesource $URL$ */ class Load { static $models = array(); static $templater = false; static $router = false;
static function model($model_name) { if (isset(self::$models[$model_name])) { return self::$models[$model_name]; } $class_name = $model_name.MODEL_POSTFIX; return self::$models[$model_name] = new $class_name; }
static function templater($path = '') { if (self::$templater) { if ($path) { self::$templater->setPath($path); } return self::$templater; } return self::$templater = new Sublimer($path); }
static function router() { return self::$router ? self::$router : self::$router = new Router; } } ?>
|