mirror of
https://github.com/dg/dibi.git
synced 2025-08-05 05:37:39 +02:00
cs
This commit is contained in:
@@ -40,9 +40,7 @@ class FirebirdDriver implements Dibi\Driver
|
||||
private $inTransaction = false;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('interbase')) {
|
||||
|
@@ -47,9 +47,7 @@ class MySqliDriver implements Dibi\Driver
|
||||
private $buffered;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('mysqli')) {
|
||||
|
@@ -37,9 +37,7 @@ class OdbcDriver implements Dibi\Driver
|
||||
private $microseconds = true;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('odbc')) {
|
||||
|
@@ -42,9 +42,7 @@ class OracleDriver implements Dibi\Driver
|
||||
private $affectedRows;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('oci8')) {
|
||||
|
@@ -42,9 +42,7 @@ class PdoDriver implements Dibi\Driver
|
||||
private $serverVersion = '';
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('pdo')) {
|
||||
|
@@ -35,9 +35,7 @@ class PostgreDriver implements Dibi\Driver
|
||||
private $affectedRows;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('pgsql')) {
|
||||
|
@@ -37,9 +37,7 @@ class SqliteDriver implements Dibi\Driver
|
||||
private $fmtDateTime;
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('sqlite3')) {
|
||||
|
@@ -39,9 +39,7 @@ class SqlsrvDriver implements Dibi\Driver
|
||||
private $version = '';
|
||||
|
||||
|
||||
/**
|
||||
* @throws Dibi\NotSupportedException
|
||||
*/
|
||||
/** @throws Dibi\NotSupportedException */
|
||||
public function __construct(array $config)
|
||||
{
|
||||
if (!extension_loaded('sqlsrv')) {
|
||||
|
@@ -201,9 +201,7 @@ class Helpers
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
/** @internal */
|
||||
public static function getTypeCache(): HashMap
|
||||
{
|
||||
if (self::$types === null) {
|
||||
@@ -279,18 +277,14 @@ class Helpers
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
/** @internal */
|
||||
public static function false2Null($val)
|
||||
{
|
||||
return $val === false ? null : $val;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @internal
|
||||
*/
|
||||
/** @internal */
|
||||
public static function intVal($value): int
|
||||
{
|
||||
if (is_int($value)) {
|
||||
|
@@ -106,18 +106,14 @@ class Column
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
/** @return mixed */
|
||||
public function getDefault()
|
||||
{
|
||||
return $this->info['default'] ?? null;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return mixed
|
||||
*/
|
||||
/** @return mixed */
|
||||
public function getVendorInfo(string $key)
|
||||
{
|
||||
return $this->info['vendor'][$key] ?? null;
|
||||
|
@@ -46,9 +46,7 @@ class Database
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return Table[]
|
||||
*/
|
||||
/** @return Table[] */
|
||||
public function getTables(): array
|
||||
{
|
||||
$this->init();
|
||||
@@ -56,9 +54,7 @@ class Database
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string[]
|
||||
*/
|
||||
/** @return string[] */
|
||||
public function getTableNames(): array
|
||||
{
|
||||
$this->init();
|
||||
|
@@ -38,9 +38,7 @@ class Result
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return Column[]
|
||||
*/
|
||||
/** @return Column[] */
|
||||
public function getColumns(): array
|
||||
{
|
||||
$this->initColumns();
|
||||
@@ -48,9 +46,7 @@ class Result
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string[]
|
||||
*/
|
||||
/** @return string[] */
|
||||
public function getColumnNames(bool $fullNames = false): array
|
||||
{
|
||||
$this->initColumns();
|
||||
|
@@ -69,9 +69,7 @@ class Table
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return Column[]
|
||||
*/
|
||||
/** @return Column[] */
|
||||
public function getColumns(): array
|
||||
{
|
||||
$this->initColumns();
|
||||
@@ -79,9 +77,7 @@ class Table
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string[]
|
||||
*/
|
||||
/** @return string[] */
|
||||
public function getColumnNames(): array
|
||||
{
|
||||
$this->initColumns();
|
||||
@@ -113,9 +109,7 @@ class Table
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return ForeignKey[]
|
||||
*/
|
||||
/** @return ForeignKey[] */
|
||||
public function getForeignKeys(): array
|
||||
{
|
||||
$this->initForeignKeys();
|
||||
@@ -123,9 +117,7 @@ class Table
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return Index[]
|
||||
*/
|
||||
/** @return Index[] */
|
||||
public function getIndexes(): array
|
||||
{
|
||||
$this->initIndexes();
|
||||
|
@@ -296,9 +296,7 @@ class Result implements IDataSource
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
*/
|
||||
/** @deprecated */
|
||||
private function oldFetchAssoc(string $assoc)
|
||||
{
|
||||
$this->seek(0);
|
||||
@@ -569,9 +567,7 @@ class Result implements IDataSource
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return Reflection\Column[]
|
||||
*/
|
||||
/** @return Reflection\Column[] */
|
||||
final public function getColumns(): array
|
||||
{
|
||||
return $this->getInfo()->getColumns();
|
||||
|
Reference in New Issue
Block a user