PHP Class Neos\ContentRepository\Migration\Transformations\ChangePropertyValue

This can apply two transformations: If newValue is set, the value will be set to this, with any occurrences of the currentValuePlaceholder replaced with the current value of the property. If search and replace are given, that replacement will be done on the value (after applying the newValue if set).
Inheritance: extends AbstractTransformation
Afficher le fichier Open project: neos/neos-development-collection

Protected Properties

Свойство Type Description
$currentValuePlaceholder string Placeholder for the current property value to be inserted in newValue.
$newValue string
$propertyName string
$replace string
$search string

Méthodes publiques

Méthode Description
execute ( NodeData $node ) : void Change the property on the given node.
isTransformable ( NodeData $node ) : boolean If the given node has the property this transformation should work on, this returns TRUE.
setCurrentValuePlaceholder ( string $currentValuePlaceholder ) : void The value of this option (defaults to "{current}") will be used to include the current property value into the new value.
setNewValue ( string $newValue ) : void New property value to be set.
setProperty ( string $propertyName ) : void Sets the name of the property to change.
setReplace ( string $replace ) : void Replacement for the search string
setSearch ( string $search ) : void Search string to replace in current property value.

Method Details

execute() public méthode

Change the property on the given node.
public execute ( NodeData $node ) : void
$node Neos\ContentRepository\Domain\Model\NodeData
Résultat void

isTransformable() public méthode

If the given node has the property this transformation should work on, this returns TRUE.
public isTransformable ( NodeData $node ) : boolean
$node Neos\ContentRepository\Domain\Model\NodeData
Résultat boolean

setCurrentValuePlaceholder() public méthode

The value of this option (defaults to "{current}") will be used to include the current property value into the new value.
public setCurrentValuePlaceholder ( string $currentValuePlaceholder ) : void
$currentValuePlaceholder string
Résultat void

setNewValue() public méthode

The value of the option "currentValuePlaceholder" (defaults to "{current}") will be used to include the current property value into the new value.
public setNewValue ( string $newValue ) : void
$newValue string
Résultat void

setProperty() public méthode

Sets the name of the property to change.
public setProperty ( string $propertyName ) : void
$propertyName string
Résultat void

setReplace() public méthode

Replacement for the search string
public setReplace ( string $replace ) : void
$replace string
Résultat void

setSearch() public méthode

Search string to replace in current property value.
public setSearch ( string $search ) : void
$search string
Résultat void

Property Details

$currentValuePlaceholder protected_oe property

Placeholder for the current property value to be inserted in newValue.
protected string $currentValuePlaceholder
Résultat string

$newValue protected_oe property

protected string $newValue
Résultat string

$propertyName protected_oe property

protected string $propertyName
Résultat string

$replace protected_oe property

protected string $replace
Résultat string