/** * 实例化HPOD对象 * @return HPdo */ public static function instance() { if (self::$_model === null) { self::$_model = new HPdo(); } return self::$_model; }
/** * 获取上次执行的 SQL 与 参数 * @return array */ public function getLastSql() { return HPdo::instance()->getLastSql(); }
public function __construct() { if ($this->_pdo === null) { $this->_pdo = HPdo::instance()->getConnect(); } }