‪TYPO3CMS  ‪main
TYPO3\CMS\Form\Mvc\ProcessingRule Class Reference

Public Member Functions

 __construct (protected readonly PropertyMapper $propertyMapper, ValidatorResolver $validatorResolver,)
 
 getPropertyMappingConfiguration ()
 
 getDataType ()
 
 setDataType (string $dataType)
 
 getValidators ()
 
 addValidator (ValidatorInterface $validator)
 
 removeAllValidators ()
 
 filterValidators (\Closure $filter)
 
 removeValidator (ValidatorInterface $validator)
 
mixed process ($value)
 
 getProcessingMessages ()
 

Protected Attributes

string $dataType
 
PropertyMappingConfiguration $propertyMappingConfiguration
 
ConjunctionValidator $validator
 
Result $processingMessages
 

Detailed Description

A processing Rule contains information for property mapping and validation.

Scope: frontend This class is NOT meant to be sub classed by developers.

Definition at line 37 of file ProcessingRule.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Form\Mvc\ProcessingRule::__construct ( protected readonly PropertyMapper  $propertyMapper,
ValidatorResolver  $validatorResolver 
)

Member Function Documentation

◆ addValidator()

TYPO3\CMS\Form\Mvc\ProcessingRule::addValidator ( ValidatorInterface  $validator)

Definition at line 101 of file ProcessingRule.php.

References TYPO3\CMS\Form\Mvc\ProcessingRule\$validator.

◆ filterValidators()

TYPO3\CMS\Form\Mvc\ProcessingRule::filterValidators ( \Closure  $filter)

◆ getDataType()

TYPO3\CMS\Form\Mvc\ProcessingRule::getDataType ( )

Definition at line 75 of file ProcessingRule.php.

References TYPO3\CMS\Form\Mvc\ProcessingRule\$dataType.

◆ getProcessingMessages()

TYPO3\CMS\Form\Mvc\ProcessingRule::getProcessingMessages ( )

◆ getPropertyMappingConfiguration()

TYPO3\CMS\Form\Mvc\ProcessingRule::getPropertyMappingConfiguration ( )

◆ getValidators()

TYPO3\CMS\Form\Mvc\ProcessingRule::getValidators ( )

Returns the child validators of the ConjunctionValidator that is bound to this processing rule

Definition at line 93 of file ProcessingRule.php.

Referenced by TYPO3\CMS\Form\Mvc\ProcessingRule\filterValidators().

◆ process()

mixed TYPO3\CMS\Form\Mvc\ProcessingRule::process (   $value)
Parameters
mixed$value
Returns
‪mixed

Definition at line 150 of file ProcessingRule.php.

◆ removeAllValidators()

TYPO3\CMS\Form\Mvc\ProcessingRule::removeAllValidators ( )

Initializes a new validator container

Definition at line 111 of file ProcessingRule.php.

References TYPO3\CMS\Form\Mvc\ProcessingRule\filterValidators().

◆ removeValidator()

TYPO3\CMS\Form\Mvc\ProcessingRule::removeValidator ( ValidatorInterface  $validator)

Removes the specified validator.

Parameters
ValidatorInterface$validator‪The validator to remove
Exceptions

Definition at line 140 of file ProcessingRule.php.

References TYPO3\CMS\Form\Mvc\ProcessingRule\$validator.

◆ setDataType()

TYPO3\CMS\Form\Mvc\ProcessingRule::setDataType ( string  $dataType)

Definition at line 83 of file ProcessingRule.php.

References TYPO3\CMS\Form\Mvc\ProcessingRule\$dataType.

Member Data Documentation

◆ $dataType

string TYPO3\CMS\Form\Mvc\ProcessingRule::$dataType
protected

The target data type the data should be converted to

Definition at line 43 of file ProcessingRule.php.

Referenced by TYPO3\CMS\Form\Mvc\ProcessingRule\getDataType(), and TYPO3\CMS\Form\Mvc\ProcessingRule\setDataType().

◆ $processingMessages

Result TYPO3\CMS\Form\Mvc\ProcessingRule::$processingMessages
protected

◆ $propertyMappingConfiguration

PropertyMappingConfiguration TYPO3\CMS\Form\Mvc\ProcessingRule::$propertyMappingConfiguration
protected

◆ $validator