mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-07 16:55:35 +08:00
update to 2.5.0-b3 (build 410)
This commit is contained in:
20
src/ZM/MySQL/MySQLManager.php
Normal file
20
src/ZM/MySQL/MySQLManager.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace ZM\MySQL;
|
||||
|
||||
|
||||
use Doctrine\DBAL\Connection;
|
||||
use Doctrine\DBAL\DriverManager;
|
||||
use Doctrine\DBAL\Exception;
|
||||
|
||||
class MySQLManager
|
||||
{
|
||||
/**
|
||||
* @return Connection
|
||||
* @throws Exception
|
||||
*/
|
||||
public static function getConnection() {
|
||||
return DriverManager::getConnection(["driverClass" => MySQLDriver::class]);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user