interface TransformationInterface (View source)

Transformation are used to change nodes as needed. They may do anything to a node in the execute() method and will be asked if they can transform a node through a call to isTransformable().

Settings given to a transformation will be passed to accordingly named setters.

Methods

bool
isTransformable(NodeData $node)

Returns true if the given node can be transformed by this transformation.

execute(NodeData $node)

Execute the transformation on the given node.

Details

bool isTransformable(NodeData $node)

Returns true if the given node can be transformed by this transformation.

Parameters

NodeData $node

Return Value

bool

NodeData execute(NodeData $node)

Execute the transformation on the given node.

Parameters

NodeData $node

Return Value

NodeData