PHP Класс lithium\data\Schema

Наследование: extends lithium\core\Object, implements ArrayAccess
Показать файл Открыть проект Примеры использования класса

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

Свойство Тип Описание
$_autoConfig
$_fields
$_locked
$_meta
$_types

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

Метод Описание
__construct ( array $config = [] ) : void Constructor.
append ( array $fields ) : void Appends additional fields to the schema. Will not overwrite existing fields if any conflicts arise.
cast ( $object, $key, $data, array $options = [] )
defaults ( $name = null )
fields ( $name = null, $key = null )
has ( $field )
is ( string $condition, string $field ) : boolean Detects properties of a field, i.e. if it supports arrays.
merge ( object $schema ) : void Merges another Schema object into the current one.
meta ( $name = null )
names ( )
offsetExists ( $key )
offsetGet ( $key )
offsetSet ( $key, $value )
offsetUnset ( $key )
reset ( )
type ( $field )

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

Метод Описание
_init ( )

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

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

Constructor.
public __construct ( array $config = [] ) : void
$config array Available configuration options are: - `'fields'` _array_
Результат void

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

protected _init ( )

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

Appends additional fields to the schema. Will not overwrite existing fields if any conflicts arise.
public append ( array $fields ) : void
$fields array New schema data.
Результат void

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

public cast ( $object, $key, $data, array $options = [] )
$options array

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

public defaults ( $name = null )

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

public fields ( $name = null, $key = null )

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

public has ( $field )

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

Detects properties of a field, i.e. if it supports arrays.
public is ( string $condition, string $field ) : boolean
$condition string
$field string
Результат boolean

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

Merges another Schema object into the current one.
public merge ( object $schema ) : void
$schema object Another `Schema` class object to be merged into the current one. If this schema contains field names that conflict with existing field names, the existing fields will not be overwritten.
Результат void

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

public meta ( $name = null )

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

public names ( )

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

public offsetExists ( $key )

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

public offsetGet ( $key )

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

public offsetSet ( $key, $value )

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

public offsetUnset ( $key )

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

public reset ( )

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

public type ( $field )

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

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

protected $_autoConfig

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

protected $_fields

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

protected $_locked

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

protected $_meta

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

protected $_types