You are here

public function ValidatorInterface::validateValue in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/ValidatorInterface.php \Symfony\Component\Validator\ValidatorInterface::validateValue()

Validates a value against a constraint or a list of constraints.

Parameters

mixed $value The value to validate.:

Constraint|Constraint[] $constraints The constraint(s) to validate against.:

array|null $groups The validation groups to validate.:

Return value

ConstraintViolationListInterface A list of constraint violations. If the list is empty, validation succeeded.

Deprecated

since version 2.5, to be removed in 3.0. Renamed to {@link Validator\ValidatorInterface::validate()} in Symfony 2.5.

2 methods override ValidatorInterface::validateValue()
RecursiveValidator::validateValue in vendor/symfony/validator/Validator/RecursiveValidator.php
Validates a value against a constraint or a list of constraints.
Validator::validateValue in vendor/symfony/validator/Validator.php
Validates a value against a constraint or a list of constraints.

File

vendor/symfony/validator/ValidatorInterface.php, line 90

Class

ValidatorInterface
Validates values and graphs of objects and arrays.

Namespace

Symfony\Component\Validator

Code

public function validateValue($value, $constraints, $groups = null);