Ejemplo n.º 1
0
 /**
  * Initialize the AAM Object
  *
  * @return void
  *
  * @access protected
  */
 protected function __construct()
 {
     //initialize the user subject
     if (get_current_user_id()) {
         $this->setUser(new AAM_Core_Subject_User(get_current_user_id()));
     } else {
         $this->setUser(new AAM_Core_Subject_Visitor(''));
     }
     //load all installed extension
     AAM_Core_Repository::getInstance()->load();
     //bootstrap the correct interface
     if (is_admin()) {
         AAM_Backend_Manager::bootstrap();
     } else {
         AAM_Frontend_Manager::bootstrap();
     }
 }
Ejemplo n.º 2
0
 /**
  * Bootstrap the manager
  * 
  * @return void
  * 
  * @access public
  */
 public static function bootstrap()
 {
     if (is_null(self::$_instance)) {
         self::$_instance = new self();
     }
 }