Class

Symfony\Component\Validator\Constraints\CollectionValidator

class CollectionValidator extends ConstraintValidator

Methods

initialize(ExecutionContext $context)

Initializes the constraint validator.

from ConstraintValidator
string getMessageTemplate()

from ConstraintValidator
array getMessageParameters()

from ConstraintValidator
Boolean isValid(mixed $value, Constraint $constraint)

Checks if the passed value is valid.

Details

in ConstraintValidator at line 35
public initialize(ExecutionContext $context)

Initializes the constraint validator.

Parameters

ExecutionContext $context The current validation context

in ConstraintValidator at line 47
public string getMessageTemplate()

Return Value

string

in ConstraintValidator at line 57
public array getMessageParameters()

Return Value

array

at line 33
public Boolean isValid(mixed $value, Constraint $constraint)

Checks if the passed value is valid.

Parameters

mixed $value The value that should be validated
Constraint $constraint The constraint for the validation

Return Value

Boolean Whether or not the value is valid