TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Extbase\Validation\Validator\ObjectValidatorInterface Interface Reference
Inheritance diagram for TYPO3\CMS\Extbase\Validation\Validator\ObjectValidatorInterface:
TYPO3\CMS\Extbase\Validation\Validator\ValidatorInterface Tx_Extbase_Validation_Validator_ObjectValidatorInterface TYPO3\CMS\Extbase\Validation\Validator\AbstractCompositeValidator TYPO3\CMS\Extbase\Validation\Validator\AbstractObjectValidator TYPO3\CMS\Extbase\Validation\Validator\GenericObjectValidator Tx_Extbase_Validation_Validator_AbstractCompositeValidator TYPO3\CMS\Extbase\Tests\Unit\Validation\Validator\Fixture\AbstractCompositeValidatorClass TYPO3\CMS\Extbase\Validation\Validator\ConjunctionValidator TYPO3\CMS\Extbase\Validation\Validator\DisjunctionValidator Tx_Extbase_Validation_Validator_AbstractObjectValidator TYPO3\CMS\Extbase\Mvc\Controller\ArgumentsValidator Tx_Extbase_Validation_Validator_GenericObjectValidator TYPO3\CMS\Extbase\Validation\Validator\CollectionValidator

Public Member Functions

 canValidate ($object)
 
 isPropertyValid ($object, $propertyName)
 
 setValidatedInstancesContainer (\SplObjectStorage $validatedInstancesContainer)
 

Detailed Description

This file is part of the TYPO3 CMS project.

It is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, either version 2 of the License, or any later version.

For the full copyright and license information, please read the LICENSE.txt file that was distributed with this source code.

The TYPO3 project - inspiring people to share! Contract for a validator

Definition at line 21 of file ObjectValidatorInterface.php.

Member Function Documentation

◆ canValidate()

TYPO3\CMS\Extbase\Validation\Validator\ObjectValidatorInterface::canValidate (   $object)

Checks the given object can be validated by the validator implementation

Parameters
object$objectThe object to be checked
Returns
boolean TRUE if this validator can validate instances of the given object or FALSE if it can't
Deprecated:
since Extbase 1.4.0, will be removed two versions after Extbase 6.1

Implemented in TYPO3\CMS\Extbase\Validation\Validator\AbstractCompositeValidator, TYPO3\CMS\Extbase\Validation\Validator\GenericObjectValidator, and TYPO3\CMS\Extbase\Mvc\Controller\ArgumentsValidator.

◆ isPropertyValid()

TYPO3\CMS\Extbase\Validation\Validator\ObjectValidatorInterface::isPropertyValid (   $object,
  $propertyName 
)

Checks if the specified property of the given object is valid.

If at least one error occurred, the result is FALSE.

Parameters
object$objectThe object containing the property to validate
string$propertyNameName of the property to validate
Returns
boolean TRUE if the property value is valid, FALSE if an error occurred
Deprecated:
since Extbase 1.4.0, will be removed two versions after Extbase 6.1

Implemented in TYPO3\CMS\Extbase\Validation\Validator\AbstractCompositeValidator, TYPO3\CMS\Extbase\Validation\Validator\GenericObjectValidator, and TYPO3\CMS\Extbase\Mvc\Controller\ArgumentsValidator.

◆ setValidatedInstancesContainer()

TYPO3\CMS\Extbase\Validation\Validator\ObjectValidatorInterface::setValidatedInstancesContainer ( \SplObjectStorage  $validatedInstancesContainer)

Allows to set a container to keep track of validated instances.

Parameters
\SplObjectStorage$validatedInstancesContainerA container to keep track of validated instances
Returns
void

Implemented in TYPO3\CMS\Extbase\Validation\Validator\GenericObjectValidator, TYPO3\CMS\Extbase\Validation\Validator\AbstractCompositeValidator, and TYPO3\CMS\Extbase\Validation\Validator\AbstractObjectValidator.