PHP Класс Sulu\Component\Content\Compat\Block\BlockProperty

Наследование: extends Sulu\Component\Content\Compat\Property, implements Sulu\Component\Content\Compat\Block\BlockPropertyInterface
Показать файл Открыть проект Примеры использования класса

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

Метод Описание
__clone ( )
__construct ( $name, $metadata, $defaultTypeName, $mandatory = false, $multilingual = false, $maxOccurs = 1, $minOccurs = 1, $params = [], $tags = [], $col = null )
addType ( BlockPropertyType $type ) adds a type.
clearProperties ( ) clears all initialized properties.
doSetValue ( $value ) Sub properties need to be referenced to the PropertyValue so that the "real" property is updated.
getChildProperties ( string $typeName ) : Sulu\Component\Content\Compat\PropertyInterface[] returns child properties of given Type.
getDefaultTypeName ( ) : string return default type name.
getIsBlock ( ) : boolean returns TRUE if property is a block.
getLength ( ) : integer Returns sizeof block.
getProperties ( integer $index ) : BlockPropertyType returns properties for given index.
getType ( string $name ) : BlockPropertyType returns type with given name.
getTypes ( ) : BlockPropertyType[] returns a list of properties managed by this block.
getValue ( ) : array | mixed get value of sub properties.
initProperties ( integer $index, string $typeName ) : BlockPropertyType initiate new child with given type name.
setPropertyValue ( PropertyValue $value )
setValue ( mixed $value ) set value of child properties.

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

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

public __clone ( )

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

public __construct ( $name, $metadata, $defaultTypeName, $mandatory = false, $multilingual = false, $maxOccurs = 1, $minOccurs = 1, $params = [], $tags = [], $col = null )

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

adds a type.
public addType ( BlockPropertyType $type )
$type BlockPropertyType

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

clears all initialized properties.
public clearProperties ( )

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

TODO: This is very tedious code. It is important to factor this out.
public doSetValue ( $value )

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

returns child properties of given Type.
public getChildProperties ( string $typeName ) : Sulu\Component\Content\Compat\PropertyInterface[]
$typeName string
Результат Sulu\Component\Content\Compat\PropertyInterface[]

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

return default type name.
public getDefaultTypeName ( ) : string
Результат string

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

returns TRUE if property is a block.
public getIsBlock ( ) : boolean
Результат boolean

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

Returns sizeof block.
public getLength ( ) : integer
Результат integer

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

returns properties for given index.
public getProperties ( integer $index ) : BlockPropertyType
$index integer
Результат BlockPropertyType

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

returns type with given name.
public getType ( string $name ) : BlockPropertyType
$name string of property
Результат BlockPropertyType

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

returns a list of properties managed by this block.
public getTypes ( ) : BlockPropertyType[]
Результат BlockPropertyType[]

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

get value of sub properties.
public getValue ( ) : array | mixed
Результат array | mixed

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

initiate new child with given type name.
public initProperties ( integer $index, string $typeName ) : BlockPropertyType
$index integer
$typeName string
Результат BlockPropertyType

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

public setPropertyValue ( PropertyValue $value )
$value Sulu\Component\Content\Document\Structure\PropertyValue

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

set value of child properties.
public setValue ( mixed $value )
$value mixed