示例#1
0
 /**
  * This implements the 'singleton' design pattern
  *
  * @param integer Options to initialize with this instance. See rcube::INIT_WITH_* constants
  *
  * @return rcube The one and only instance
  */
 static function get_instance($mode = 0)
 {
     if (!self::$instance) {
         self::$instance = new rcube();
         self::$instance->init($mode);
     }
     return self::$instance;
 }