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
Datei anzeigen Open project: neos/neos-development-collection

Protected Properties

Property Type Description
$currentValuePlaceholder string Placeholder for the current property value to be inserted in newValue.
$newValue string
$propertyName string
$replace string
$search string

Public Methods

Method 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 method

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

isTransformable() public method

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
return boolean

setCurrentValuePlaceholder() public method

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
return void

setNewValue() public method

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
return void

setProperty() public method

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

setReplace() public method

Replacement for the search string
public setReplace ( string $replace ) : void
$replace string
return void

setSearch() public method

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

Property Details

$currentValuePlaceholder protected_oe property

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

$newValue protected_oe property

protected string $newValue
return string

$propertyName protected_oe property

protected string $propertyName
return string

$replace protected_oe property

protected string $replace
return string