PHP Класс Prado\Data\Common\TDbMetaData

Use the {@link getTableInfo} method to retrieve a table information.
С версии: 3.1
Наследование: extends Prado\TComponent
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$delimiterIdentifier array

Открытые методы

Метод Описание
__construct ( $conn )
createCommandBuilder ( $tableName = null ) : TDbCommandBuilder Creates a command builder for a given table name.
findTableNames ( string $schema = '' ) : array Returns all table names in the database.
getDbConnection ( ) : TDbConnection
getInstance ( $conn ) : TDbMetaData Obtain database specific TDbMetaData class using the driver name of the database connection.
getTableInfo ( $tableName = null ) : TDbTableInfo Obtains table meta data information for the current connection and given table name.
quoteColumnAlias ( string $name ) : string Quotes a column alias for use in a query.
quoteColumnName ( string $name ) : string Quotes a column name for use in a query.
quoteTableName ( string $name ) : string Quotes a table name for use in a query.

Защищенные методы

Метод Описание
createTableInfo ( $tableName ) : TDbTableInfo This method should be implemented by decendent classes.
getTableInfoClass ( ) : string

Описание методов

__construct() публичный метод

public __construct ( $conn )

createCommandBuilder() публичный метод

Creates a command builder for a given table name.
public createCommandBuilder ( $tableName = null ) : TDbCommandBuilder
Результат TDbCommandBuilder command builder instance for the given table.

createTableInfo() абстрактный защищенный метод

This method should be implemented by decendent classes.
abstract protected createTableInfo ( $tableName ) : TDbTableInfo
Результат TDbTableInfo driver dependent create builder.

findTableNames() абстрактный публичный метод

This method should be overridden by child classes in order to support this feature because the default implementation simply throws an exception.
abstract public findTableNames ( string $schema = '' ) : array
$schema string the schema of the tables. Defaults to empty string, meaning the current or default schema. If not empty, the returned table names will be prefixed with the schema name.
Результат array all table names in the database.

getDbConnection() публичный метод

public getDbConnection ( ) : TDbConnection
Результат TDbConnection database connection.

getInstance() публичный статический метод

Obtain database specific TDbMetaData class using the driver name of the database connection.
public static getInstance ( $conn ) : TDbMetaData
Результат TDbMetaData database specific TDbMetaData.

getTableInfo() публичный метод

Obtains table meta data information for the current connection and given table name.
public getTableInfo ( $tableName = null ) : TDbTableInfo
Результат TDbTableInfo table information.

getTableInfoClass() защищенный метод

protected getTableInfoClass ( ) : string
Результат string TDbTableInfo class name.

quoteColumnAlias() публичный метод

Quotes a column alias for use in a query.
public quoteColumnAlias ( string $name ) : string
$name string column alias
Результат string the properly quoted column alias

quoteColumnName() публичный метод

Quotes a column name for use in a query.
public quoteColumnName ( string $name ) : string
$name string column name
Результат string the properly quoted column name

quoteTableName() публичный метод

Quotes a table name for use in a query.
public quoteTableName ( string $name ) : string
$name string table name
Результат string the properly quoted table name

Описание свойств

$delimiterIdentifier защищенное статическое свойство

protected static array $delimiterIdentifier
Результат array