Ejemplo n.º 1
0
 public static function getInstance()
 {
     if (!isset(self::$_instance)) {
         self::$_instance = new DbConnection();
     }
     return self::$_instance;
 }
 /**
  * @return the only instance during current request.
  */
 public static function getInstance()
 {
     if (self::$_instance == NULL) {
         self::$_instance = new DbConnection();
     }
     return self::$_instance;
 }
Ejemplo n.º 3
0
 public static function getInstance()
 {
     if (!self::$_instance instanceof self) {
         self::$_instance = new self();
     }
     return self::$_instance;
 }