PHP Класс Spot\Query\Resolver

Показать файл Открыть проект

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

Свойство Тип Описание
$_noQuote
$mapper Spot\Mapper

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

Метод Описание
__construct ( Mapper $mapper ) Constructor Method
create ( string $table, array $data ) Create new row object with set properties
dataWithFieldAliasMappings ( array $data ) Taken given field name/value inputs and map them to their aliased names
dropTable ( string $table ) : boolean Drop Table
escapeIdentifier ( string $identifier ) : string Escape/quote identifier
exec ( Query $query ) : Doctrine\DBAL\Driver\Statement | integer Execute provided query and return result
migrate ( ) : boolean Migrate table structure changes to database
migrateCreateSchema ( ) : Doctrine\DBAL\Schema\Schema Migrate create schema
noQuote ( boolean $noQuote = true ) Set field and value quoting on/off - maily used for testing output SQL since quoting is different per platform
read ( Query $query ) : Collection Find records with custom SQL query
trimSchemaName ( string $identifier ) : string Trim a leading schema name separated by a dot if present
truncate ( string $table, boolean $cascade = false ) Truncate Table
update ( string $table, array $data, array $where ) Update

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

Метод Описание
addForeignKeys ( Doctrine\DBAL\Schema\Table $table ) : Doctrine\DBAL\Schema\Table Add foreign keys from BelongsTo relations to the table schema

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

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

Constructor Method
public __construct ( Mapper $mapper )
$mapper Spot\Mapper

addForeignKeys() защищенный Метод

Add foreign keys from BelongsTo relations to the table schema
protected addForeignKeys ( Doctrine\DBAL\Schema\Table $table ) : Doctrine\DBAL\Schema\Table
$table Doctrine\DBAL\Schema\Table
Результат Doctrine\DBAL\Schema\Table

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

Create new row object with set properties
public create ( string $table, array $data )
$table string Table name
$data array Array of data to save in 'field' => 'value' format

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

Taken given field name/value inputs and map them to their aliased names
public dataWithFieldAliasMappings ( array $data )
$data array

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

Drop Table
public dropTable ( string $table ) : boolean
$table string Table name
Результат boolean

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

Escape/quote identifier
public escapeIdentifier ( string $identifier ) : string
$identifier string
Результат string

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

Execute provided query and return result
public exec ( Query $query ) : Doctrine\DBAL\Driver\Statement | integer
$query Spot\Query SQL query to execute
Результат Doctrine\DBAL\Driver\Statement | integer

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

Migrate table structure changes to database
public migrate ( ) : boolean
Результат boolean

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

Migrate create schema
public migrateCreateSchema ( ) : Doctrine\DBAL\Schema\Schema
Результат Doctrine\DBAL\Schema\Schema

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

Set field and value quoting on/off - maily used for testing output SQL since quoting is different per platform
public noQuote ( boolean $noQuote = true )
$noQuote boolean

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

Find records with custom SQL query
public read ( Query $query ) : Collection
$query Spot\Query SQL query to execute
Результат Spot\Entity\Collection

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

Trim a leading schema name separated by a dot if present
public trimSchemaName ( string $identifier ) : string
$identifier string
Результат string

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

Truncate Table
public truncate ( string $table, boolean $cascade = false )
$table string Table name
$cascade boolean

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

Update
public update ( string $table, array $data, array $where )
$table string Table name
$data array Array of data for WHERE clause in 'field' => 'value' format
$where array

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

$_noQuote защищенное свойство

protected $_noQuote

$mapper защищенное свойство

protected Mapper,Spot $mapper
Результат Spot\Mapper