Symfony\Component\Form\FormConfigBuilderInterface::addModelTransformer
Prepends / appends a transformer to the normalization transformer chain.
The transform method of the transformer is used to convert data from the model to the normalized format. The reverseTransform method of the transformer is used to convert from the normalized to the model format.
Signature
public function addModelTransformer(DataTransformerInterface
$modelTransformer,
[Boolean
$forceAppend = false] )
Parameters
$modelTransformer
— Symfony\Component\Form\DataTransformerInterface
$forceAppend
— object- if set to true, append instead of prepending
Returns
- self
- The configuration object.