コード例 #1
0
ファイル: Router.class.php プロジェクト: xxlixin1993/Frame
 /**
  * 获取Router实例
  * @return  object  Router实例
  */
 public static function getInstance()
 {
     if (empty(self::$instance)) {
         self::$instance = new self();
     }
     return self::$instance;
 }
コード例 #2
0
ファイル: router.php プロジェクト: qzsolt/framework
 private static function getInstance()
 {
     if (is_null(self::$instance)) {
         self::$instance = new self();
     }
     return self::$instance;
 }