PHP Класс Sulu\Component\Content\SimpleContentType

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

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

Свойство Тип Описание
$defaultValue mixed default value if node does not have the property.

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

Метод Описание
__construct ( $name, $defaultValue = null )
__get ( $property ) magic getter for twig templates.
exportData ( $propertyValue )
getContentData ( Sulu\Component\Content\Compat\PropertyInterface $property )
getDefaultParams ( Sulu\Component\Content\Compat\PropertyInterface $property = null )
getDefaultValue ( )
getName ( ) : string Returns the name of the content type.
getReferencedUuids ( Sulu\Component\Content\Compat\PropertyInterface $property )
getType ( )
getViewData ( Sulu\Component\Content\Compat\PropertyInterface $property )
hasValue ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
importData ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $value, $userId, $webspaceKey, $languageCode, $segmentKey = null )
read ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
remove ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
write ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $userId, $webspaceKey, $languageCode, $segmentKey )

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

Метод Описание
decodeValue ( mixed $value ) : mixed Decodes value from database.
encodeValue ( mixed $value ) : mixed Prepares value for database.
removeIllegalCharacters ( string $content ) : string Remove illegal characters from content string, else PHPCR would throw an PHPCR\ValueFormatException if an illegal characters is detected.

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

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

public __construct ( $name, $defaultValue = null )

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

magic getter for twig templates.
public __get ( $property )
$property string name of property

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

Decodes value from database.
protected decodeValue ( mixed $value ) : mixed
$value mixed
Результат mixed

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

Prepares value for database.
protected encodeValue ( mixed $value ) : mixed
$value mixed
Результат mixed

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

public exportData ( $propertyValue )

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

public getContentData ( Sulu\Component\Content\Compat\PropertyInterface $property )
$property Sulu\Component\Content\Compat\PropertyInterface

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

public getDefaultParams ( Sulu\Component\Content\Compat\PropertyInterface $property = null )
$property Sulu\Component\Content\Compat\PropertyInterface

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

public getDefaultValue ( )

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

Returns the name of the content type.
public getName ( ) : string
Результат string

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

public getReferencedUuids ( Sulu\Component\Content\Compat\PropertyInterface $property )
$property Sulu\Component\Content\Compat\PropertyInterface

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

public getType ( )

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

public getViewData ( Sulu\Component\Content\Compat\PropertyInterface $property )
$property Sulu\Component\Content\Compat\PropertyInterface

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

public hasValue ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
$node PHPCR\NodeInterface
$property Sulu\Component\Content\Compat\PropertyInterface

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

public importData ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $value, $userId, $webspaceKey, $languageCode, $segmentKey = null )
$node PHPCR\NodeInterface
$property Sulu\Component\Content\Compat\PropertyInterface

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

public read ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
$node PHPCR\NodeInterface
$property Sulu\Component\Content\Compat\PropertyInterface

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

public remove ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $webspaceKey, $languageCode, $segmentKey )
$node PHPCR\NodeInterface
$property Sulu\Component\Content\Compat\PropertyInterface

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

Remove illegal characters from content string, else PHPCR would throw an PHPCR\ValueFormatException if an illegal characters is detected.
protected removeIllegalCharacters ( string $content ) : string
$content string
Результат string

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

public write ( PHPCR\NodeInterface $node, Sulu\Component\Content\Compat\PropertyInterface $property, $userId, $webspaceKey, $languageCode, $segmentKey )
$node PHPCR\NodeInterface
$property Sulu\Component\Content\Compat\PropertyInterface

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

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

default value if node does not have the property.
protected mixed $defaultValue
Результат mixed