PHP Интерфейс Fakerino\Core\Database\DbInterface

Автор: Nicola Pietroluongo ([email protected])
Показать файл Открыть проект Примеры использования интерфейса

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

Метод Описание
connect ( ) : boolean Makes a database connection.
getColumnLength ( integer $num ) : integer Returns the length of the $num column.
getColumnName ( integer $num ) : string Returns the name of the $num column.
getColumnType ( integer $num ) : string Returns the type of the $num column.
getFakeType ( string $columnType ) : string Gets the Fakerino columnType.
getTotalColumns ( ) : integer Gets the number of column in the table.
insert ( DbRowEntity $row ) : boolean Inserts row in $tableName.
isColumnAutoincrement ( integer $num ) : boolean Returns true if the column is autoincrement.
setTable ( string $tableName ) Sets the connection with the $tableName.

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

connect() публичный Метод

Makes a database connection.
public connect ( ) : boolean
Результат boolean

getColumnLength() публичный Метод

Returns the length of the $num column.
public getColumnLength ( integer $num ) : integer
$num integer
Результат integer

getColumnName() публичный Метод

Returns the name of the $num column.
public getColumnName ( integer $num ) : string
$num integer
Результат string mixed

getColumnType() публичный Метод

Returns the type of the $num column.
public getColumnType ( integer $num ) : string
$num integer
Результат string

getFakeType() публичный Метод

Gets the Fakerino columnType.
public getFakeType ( string $columnType ) : string
$columnType string
Результат string

getTotalColumns() публичный Метод

Gets the number of column in the table.
public getTotalColumns ( ) : integer
Результат integer

insert() публичный Метод

Inserts row in $tableName.
public insert ( DbRowEntity $row ) : boolean
$row DbRowEntity
Результат boolean

isColumnAutoincrement() публичный Метод

Returns true if the column is autoincrement.
public isColumnAutoincrement ( integer $num ) : boolean
$num integer
Результат boolean

setTable() публичный Метод

Sets the connection with the $tableName.
public setTable ( string $tableName )
$tableName string