PHP Класс Pimcore\Model\Object\ClassDefinition\Data

Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$columnType string | array | array
$datatype string
$fieldtype string
$index integer
$invisible boolean
$locked boolean
$mandatory boolean
$name string
$noteditable boolean
$permissions array
$queryColumnType string | array | array
$relationType boolean
$style boolean
$title string
$tooltip string
$validFilterOperators array
$visibleGridView boolean
$visibleSearch boolean

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

Свойство Тип Описание
$dropNullValues If set to true then null values will not be exported.

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

Метод Описание
adoptMasterDefinition ( Data $masterDefinition )
checkValidity ( mixed $data, boolean $omitMandatoryCheck = false ) Checks if data is valid for current data field
getAsFloatCast ( $number ) : float
getAsIntegerCast ( $number ) : integer | null
getCacheTags ( mixed $data, array $tags = [] ) : array This is a dummy and is mostly implemented by relation types
getColumnType ( ) : string | array
getDataForEditmode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : mixed Returns the data for the editmode
getDataForSearchIndex ( $object, mixed $params = [] ) : string
getDataFromEditmode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : mixed Converts data from editmode to internal eg. Image-Id to Asset\Image object
getDatatype ( ) : string
getDiffDataForEditMode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : null | array Returns the data for the editmode in the format expected by the object merger plugin.
getDiffDataFromEditmode ( $data, null $object = null, mixed $params = [] ) : mixed Converts the data sent from the object merger plugin back to the internal object. Similar to getDiffDataForEditMode() an array of data elements is passed in containing the following attributes: - "field" => the name of (this) field - "key" => the key of the data element - "data" => the data
getDropNullValues ( )
getFieldtype ( ) : string
getFilterCondition ( $value, $operator ) : string returns sql query statement to filter according to this data types value(s)
getFilterConditionExt ( $value, $operator, $params = [] ) : string returns sql query statement to filter according to this data types value(s)
getForCsvExport ( AbstractObject $object, array $params = [] ) : string converts object data to a simple string value or CSV Export
getForWebserviceExport ( AbstractObject $object, mixed $params = [] ) : mixed converts data to be exposed via webservices
getFromCsvImport ( $importValue, null | AbstractObject $object = null, mixed $params = [] ) : mixed
getFromWebserviceImport ( mixed $value, null | AbstractObject $object = null, mixed $params = [], $idMapper = null ) : mixed converts data to be imported via webservices
getGetterCode ( $class ) : string Creates getter code which is used for generation of php file for object classes using this data type
getGetterCodeFieldcollection ( $fieldcollectionDefinition ) : string Creates getter code which is used for generation of php file for fieldcollectionk classes using this data type
getGetterCodeLocalizedfields ( $class ) : string Creates getter code which is used for generation of php file for localized fields in classes using this data type
getGetterCodeObjectbrick ( $brickClass ) : string Creates getter code which is used for generation of php file for object brick classes using this data type
getIndex ( ) : integer
getInvisible ( ) : boolean
getLocked ( ) : boolean
getMandatory ( ) : boolean
getName ( ) : string
getNoteditable ( ) : boolean
getPermissions ( ) : array
getPhpdocType ( ) : string
getQueryColumnType ( ) : string | array
getSetterCode ( $class ) : string Creates setter code which is used for generation of php file for object classes using this data type
getSetterCodeFieldcollection ( $fieldcollectionDefinition ) : string Creates setter code which is used for generation of php file for fieldcollection classes using this data type
getSetterCodeLocalizedfields ( $class ) : string Creates setter code which is used for generation of php file for localized fields in classes using this data type
getSetterCodeObjectbrick ( $brickClass ) : string Creates setter code which is used for generation of php file for object brick classes using this data type
getStyle ( ) : boolean
getTitle ( ) : string
getTooltip ( ) : string
getVersionPreview ( $data, null | AbstractObject $object = null, mixed $params = [] ) : string
getVisibleGridView ( ) : boolean
getVisibleSearch ( ) : boolean
isDiffChangeAllowed ( string $object, mixed $params = [] ) : boolean True if change is allowed in edit mode.
isEmpty ( Concrete $data ) : boolean
isRelationType ( ) : boolean
marshal ( mixed $value, AbstractObject $object = null, mixed $params = [] ) : mixed Encode value for packing it into a single column.
resolveDependencies ( $data ) : array
setColumnType ( string | array $columnType )
setDatatype ( string $datatype )
setDropNullValues ( $dropNullValues )
setFieldtype ( string $fieldtype )
setIndex ( integer $index )
setInvisible ( $invisible )
setLocked ( $locked )
setMandatory ( boolean $mandatory )
setName ( string $name )
setNoteditable ( boolean $noteditable )
setPermissions ( array $permissions )
setQueryColumnType ( string | array $queryColumnType )
setStyle ( $style )
setTitle ( string $title )
setTooltip ( $tooltip )
setValues ( array $data = [] )
setVisibleGridView ( $visibleGridView )
setVisibleSearch ( $visibleSearch )
synchronizeWithMasterDefinition ( Data $masterDefinition )
unmarshal ( $data, AbstractObject $object = null, $params = [] ) : mixed See marshal

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

Метод Описание
getDataFromObjectParam ( $object, array $params = [] ) : mixed

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

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

public adoptMasterDefinition ( Data $masterDefinition )
$masterDefinition Data

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

Checks if data is valid for current data field
public checkValidity ( mixed $data, boolean $omitMandatoryCheck = false )
$data mixed
$omitMandatoryCheck boolean

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

public getAsFloatCast ( $number ) : float
$number
Результат float

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

public getAsIntegerCast ( $number ) : integer | null
$number
Результат integer | null

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

This is a dummy and is mostly implemented by relation types
public getCacheTags ( mixed $data, array $tags = [] ) : array
$data mixed
$tags array
Результат array

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

public getColumnType ( ) : string | array
Результат string | array | array

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

Returns the data for the editmode
abstract public getDataForEditmode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : mixed
$data mixed
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

public getDataForSearchIndex ( $object, mixed $params = [] ) : string
$object
$params mixed
Результат string

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

Converts data from editmode to internal eg. Image-Id to Asset\Image object
abstract public getDataFromEditmode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : mixed
$data mixed
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

protected getDataFromObjectParam ( $object, array $params = [] ) : mixed
$object
$params array
Результат mixed

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

public getDatatype ( ) : string
Результат string

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

The return value is a list of data definitions containing the following attributes: - "field" => the name of the object field - "key" => a unique key identifying the data element - "type" => the type of the data component - "value" => the value used as preview - "data" => the actual data which is then sent back again by the editor. Note that the data is opaque and will not be touched by the editor in any way. - "disabled" => whether the data element can be edited or not - "title" => pretty name describing the data element
public getDiffDataForEditMode ( mixed $data, null | AbstractObject $object = null, mixed $params = [] ) : null | array
$data mixed
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат null | array

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

Converts the data sent from the object merger plugin back to the internal object. Similar to getDiffDataForEditMode() an array of data elements is passed in containing the following attributes: - "field" => the name of (this) field - "key" => the key of the data element - "data" => the data
public getDiffDataFromEditmode ( $data, null $object = null, mixed $params = [] ) : mixed
$data
$object null
$params mixed
Результат mixed

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

public static getDropNullValues ( )

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

public getFieldtype ( ) : string
Результат string

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

returns sql query statement to filter according to this data types value(s)
public getFilterCondition ( $value, $operator ) : string
$value
$operator
Результат string

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

returns sql query statement to filter according to this data types value(s)
public getFilterConditionExt ( $value, $operator, $params = [] ) : string
$value
$operator
$params optional params used to change the behavior
Результат string

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

converts object data to a simple string value or CSV Export
public getForCsvExport ( AbstractObject $object, array $params = [] ) : string
$object Pimcore\Model\Object\AbstractObject
$params array
Результат string

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

converts data to be exposed via webservices
public getForWebserviceExport ( AbstractObject $object, mixed $params = [] ) : mixed
$object Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

public getFromCsvImport ( $importValue, null | AbstractObject $object = null, mixed $params = [] ) : mixed
$importValue
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

converts data to be imported via webservices
public getFromWebserviceImport ( mixed $value, null | AbstractObject $object = null, mixed $params = [], $idMapper = null ) : mixed
$value mixed
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

Creates getter code which is used for generation of php file for object classes using this data type
public getGetterCode ( $class ) : string
$class
Результат string

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

Creates getter code which is used for generation of php file for fieldcollectionk classes using this data type
public getGetterCodeFieldcollection ( $fieldcollectionDefinition ) : string
$fieldcollectionDefinition
Результат string

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

Creates getter code which is used for generation of php file for localized fields in classes using this data type
public getGetterCodeLocalizedfields ( $class ) : string
$class
Результат string

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

Creates getter code which is used for generation of php file for object brick classes using this data type
public getGetterCodeObjectbrick ( $brickClass ) : string
$brickClass
Результат string

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

public getIndex ( ) : integer
Результат integer

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

public getInvisible ( ) : boolean
Результат boolean

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

public getLocked ( ) : boolean
Результат boolean

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

public getMandatory ( ) : boolean
Результат boolean

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

public getName ( ) : string
Результат string

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

public getNoteditable ( ) : boolean
Результат boolean

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

public getPermissions ( ) : array
Результат array

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

public getPhpdocType ( ) : string
Результат string

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

public getQueryColumnType ( ) : string | array
Результат string | array | array

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

Creates setter code which is used for generation of php file for object classes using this data type
public getSetterCode ( $class ) : string
$class
Результат string

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

Creates setter code which is used for generation of php file for fieldcollection classes using this data type
public getSetterCodeFieldcollection ( $fieldcollectionDefinition ) : string
$fieldcollectionDefinition
Результат string

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

Creates setter code which is used for generation of php file for localized fields in classes using this data type
public getSetterCodeLocalizedfields ( $class ) : string
$class
Результат string

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

Creates setter code which is used for generation of php file for object brick classes using this data type
public getSetterCodeObjectbrick ( $brickClass ) : string
$brickClass
Результат string

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

public getStyle ( ) : boolean
Результат boolean

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

public getTitle ( ) : string
Результат string

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

public getTooltip ( ) : string
Результат string

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

public getVersionPreview ( $data, null | AbstractObject $object = null, mixed $params = [] ) : string
$data
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
Результат string

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

public getVisibleGridView ( ) : boolean
Результат boolean

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

public getVisibleSearch ( ) : boolean
Результат boolean

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

True if change is allowed in edit mode.
public isDiffChangeAllowed ( string $object, mixed $params = [] ) : boolean
$object string
$params mixed
Результат boolean

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

public isEmpty ( Concrete $data ) : boolean
$data Pimcore\Model\Object\Concrete
Результат boolean

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

public isRelationType ( ) : boolean
Результат boolean

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

Encode value for packing it into a single column.
public marshal ( mixed $value, AbstractObject $object = null, mixed $params = [] ) : mixed
$value mixed
$object Pimcore\Model\Object\AbstractObject
$params mixed
Результат mixed

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

public resolveDependencies ( $data ) : array
$data
Результат array

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

public setColumnType ( string | array $columnType )
$columnType string | array

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

public setDatatype ( string $datatype )
$datatype string

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

public static setDropNullValues ( $dropNullValues )
$dropNullValues

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

public setFieldtype ( string $fieldtype )
$fieldtype string

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

public setIndex ( integer $index )
$index integer

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

public setInvisible ( $invisible )
$invisible

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

public setLocked ( $locked )
$locked

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

public setMandatory ( boolean $mandatory )
$mandatory boolean

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

public setName ( string $name )
$name string

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

public setNoteditable ( boolean $noteditable )
$noteditable boolean

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

public setPermissions ( array $permissions )
$permissions array

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

public setQueryColumnType ( string | array $queryColumnType )
$queryColumnType string | array

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

public setStyle ( $style )
$style

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

public setTitle ( string $title )
$title string

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

public setTooltip ( $tooltip )
$tooltip

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

public setValues ( array $data = [] )
$data array

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

public setVisibleGridView ( $visibleGridView )
$visibleGridView

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

public setVisibleSearch ( $visibleSearch )
$visibleSearch

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

public synchronizeWithMasterDefinition ( Data $masterDefinition )
$masterDefinition Data

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

See marshal
public unmarshal ( $data, AbstractObject $object = null, $params = [] ) : mixed
$object Pimcore\Model\Object\AbstractObject
Результат mixed

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

$columnType публичное свойство

| array
public string|array $columnType
Результат string | array

$datatype публичное свойство

public string $datatype
Результат string

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

If set to true then null values will not be exported.
protected static $dropNullValues

$fieldtype публичное свойство

public string $fieldtype
Результат string

$index публичное свойство

public int $index
Результат integer

$invisible публичное свойство

public bool $invisible
Результат boolean

$locked публичное свойство

public bool $locked
Результат boolean

$mandatory публичное свойство

public bool $mandatory
Результат boolean

$name публичное свойство

public string $name
Результат string

$noteditable публичное свойство

public bool $noteditable
Результат boolean

$permissions публичное свойство

public array $permissions
Результат array

$queryColumnType публичное свойство

| array
public string|array $queryColumnType
Результат string | array

$relationType публичное свойство

public bool $relationType
Результат boolean

$style публичное свойство

public bool $style
Результат boolean

$title публичное свойство

public string $title
Результат string

$tooltip публичное свойство

public string $tooltip
Результат string

$validFilterOperators публичное статическое свойство

public static array $validFilterOperators
Результат array

$visibleGridView публичное свойство

public bool $visibleGridView
Результат boolean

$visibleSearch публичное свойство

public bool $visibleSearch
Результат boolean