变更
This commit is contained in:
+22
-1
@@ -13,7 +13,7 @@ use Kiri\Server\Abstracts\StatusEnum;
|
||||
use Swoole\Timer;
|
||||
|
||||
/**
|
||||
*
|
||||
* @mixin \PDO
|
||||
*/
|
||||
class PDO implements StopHeartbeatCheck
|
||||
{
|
||||
@@ -89,6 +89,27 @@ class PDO implements StopHeartbeatCheck
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param string $name
|
||||
* @param array $arguments
|
||||
* @return mixed
|
||||
*/
|
||||
public function __call(string $name, array $arguments)
|
||||
{
|
||||
return $this->_pdo()->{$name}(...$arguments);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @param string $sql
|
||||
* @return PDOStatement|bool
|
||||
*/
|
||||
public function prepare(string $sql): PDOStatement|bool
|
||||
{
|
||||
return $this->_pdo()->prepare($sql);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user